@mseva/digit-ui-module-mcollect 1.0.0 → 1.0.1
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.
- package/dist/index.js +1 -1
- package/package.json +5 -3
package/dist/index.js
CHANGED
|
@@ -7,4 +7,4 @@ var e,t=require("@mseva/digit-ui-react-components"),n=require("react"),r=(e=n)&&
|
|
|
7
7
|
* This source code is licensed under the MIT license found in the
|
|
8
8
|
* LICENSE file in the root directory of this source tree.
|
|
9
9
|
*/
|
|
10
|
-
var me="function"==typeof Symbol&&Symbol.for,ve=me?Symbol.for("react.element"):60103,he=me?Symbol.for("react.portal"):60106,ge=me?Symbol.for("react.fragment"):60107,ye=me?Symbol.for("react.strict_mode"):60108,_e=me?Symbol.for("react.profiler"):60114,Ee=me?Symbol.for("react.provider"):60109,be=me?Symbol.for("react.context"):60110,Ce=me?Symbol.for("react.async_mode"):60111,Se=me?Symbol.for("react.concurrent_mode"):60111,Le=me?Symbol.for("react.forward_ref"):60112,Ne=me?Symbol.for("react.suspense"):60113,Ae=me?Symbol.for("react.suspense_list"):60120,we=me?Symbol.for("react.memo"):60115,xe=me?Symbol.for("react.lazy"):60116,Ie=me?Symbol.for("react.block"):60121,Te=me?Symbol.for("react.fundamental"):60117,De=me?Symbol.for("react.responder"):60118,Oe=me?Symbol.for("react.scope"):60119;function Re(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case ve:switch(e=e.type){case Ce:case Se:case ge:case _e:case ye:case Ne:return e;default:switch(e=e&&e.$$typeof){case be:case Le:case xe:case we:case Ee:return e;default:return t}}case he:return t}}}function Pe(e){return Re(e)===Se}var ke={AsyncMode:Ce,ConcurrentMode:Se,ContextConsumer:be,ContextProvider:Ee,Element:ve,ForwardRef:Le,Fragment:ge,Lazy:xe,Memo:we,Portal:he,Profiler:_e,StrictMode:ye,Suspense:Ne,isAsyncMode:function(e){return Pe(e)||Re(e)===Ce},isConcurrentMode:Pe,isContextConsumer:function(e){return Re(e)===be},isContextProvider:function(e){return Re(e)===Ee},isElement:function(e){return"object"==typeof e&&null!==e&&e.$$typeof===ve},isForwardRef:function(e){return Re(e)===Le},isFragment:function(e){return Re(e)===ge},isLazy:function(e){return Re(e)===xe},isMemo:function(e){return Re(e)===we},isPortal:function(e){return Re(e)===he},isProfiler:function(e){return Re(e)===_e},isStrictMode:function(e){return Re(e)===ye},isSuspense:function(e){return Re(e)===Ne},isValidElementType:function(e){return"string"==typeof e||"function"==typeof e||e===ge||e===Se||e===_e||e===ye||e===Ne||e===Ae||"object"==typeof e&&null!==e&&(e.$$typeof===xe||e.$$typeof===we||e.$$typeof===Ee||e.$$typeof===be||e.$$typeof===Le||e.$$typeof===Te||e.$$typeof===De||e.$$typeof===Oe||e.$$typeof===Ie)},typeOf:Re},Be=f(function(e,t){"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,n=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,l=e?Symbol.for("react.provider"):60109,u=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,s=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,v=e?Symbol.for("react.lazy"):60116,h=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function E(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case n:var p=e.type;switch(p){case c:case s:case o:case a:case i:case d:return p;default:var h=p&&p.$$typeof;switch(h){case u:case f:case v:case m:case l:return h;default:return t}}case r:return t}}}var b=s,C=u,S=l,L=n,N=f,A=o,w=v,x=m,I=r,T=a,D=i,O=d,R=!1;function P(e){return E(e)===s}t.AsyncMode=c,t.ConcurrentMode=b,t.ContextConsumer=C,t.ContextProvider=S,t.Element=L,t.ForwardRef=N,t.Fragment=A,t.Lazy=w,t.Memo=x,t.Portal=I,t.Profiler=T,t.StrictMode=D,t.Suspense=O,t.isAsyncMode=function(e){return R||(R=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),P(e)||E(e)===c},t.isConcurrentMode=P,t.isContextConsumer=function(e){return E(e)===u},t.isContextProvider=function(e){return E(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===n},t.isForwardRef=function(e){return E(e)===f},t.isFragment=function(e){return E(e)===o},t.isLazy=function(e){return E(e)===v},t.isMemo=function(e){return E(e)===m},t.isPortal=function(e){return E(e)===r},t.isProfiler=function(e){return E(e)===a},t.isStrictMode=function(e){return E(e)===i},t.isSuspense=function(e){return E(e)===d},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===s||e===a||e===i||e===d||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===v||e.$$typeof===m||e.$$typeof===l||e.$$typeof===u||e.$$typeof===f||e.$$typeof===g||e.$$typeof===y||e.$$typeof===_||e.$$typeof===h)},t.typeOf=E}()}),Ue=f(function(e){e.exports="production"===process.env.NODE_ENV?ke:Be}),Me=Object.getOwnPropertySymbols,je=Object.prototype.hasOwnProperty,Fe=Object.prototype.propertyIsEnumerable;function He(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var $e=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,r,o=He(e),i=1;i<arguments.length;i++){for(var a in n=Object(arguments[i]))je.call(n,a)&&(o[a]=n[a]);if(Me){r=Me(n);for(var l=0;l<r.length;l++)Fe.call(n,r[l])&&(o[r[l]]=n[r[l]])}}return o},ze="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",Ve=Function.call.bind(Object.prototype.hasOwnProperty),We=function(){};if("production"!==process.env.NODE_ENV){var qe=ze,Ge={},Ke=Ve;We=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function Ye(e,t,n,r,o){if("production"!==process.env.NODE_ENV)for(var i in e)if(Ke(e,i)){var a;try{if("function"!=typeof e[i]){var l=Error((r||"React class")+": "+n+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}a=e[i](t,i,r,n,null,qe)}catch(e){a=e}if(!a||a instanceof Error||We((r||"React class")+": type specification of "+n+" `"+i+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof a+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),a instanceof Error&&!(a.message in Ge)){Ge[a.message]=!0;var u=o?o():"";We("Failed "+n+" type: "+a.message+(null!=u?u:""))}}}Ye.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(Ge={})};var Je=Ye,Ze=function(){};function Qe(){return null}function Xe(){}function et(){}"production"!==process.env.NODE_ENV&&(Ze=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),et.resetWarningCache=Xe;var tt=f(function(e){e.exports="production"!==process.env.NODE_ENV?function(e,t){var n="function"==typeof Symbol&&Symbol.iterator,r={array:l("array"),bigint:l("bigint"),bool:l("boolean"),func:l("function"),number:l("number"),object:l("object"),string:l("string"),symbol:l("symbol"),any:a(Qe),arrayOf:function(e){return a(function(t,n,r,o,a){if("function"!=typeof e)return new i("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var l=t[n];if(!Array.isArray(l))return new i("Invalid "+o+" `"+a+"` of type `"+s(l)+"` supplied to `"+r+"`, expected an array.");for(var u=0;u<l.length;u++){var c=e(l,u,r,o,a+"["+u+"]",ze);if(c instanceof Error)return c}return null})},element:a(function(t,n,r,o,a){var l=t[n];return e(l)?null:new i("Invalid "+o+" `"+a+"` of type `"+s(l)+"` supplied to `"+r+"`, expected a single ReactElement.")}),elementType:a(function(e,t,n,r,o){var a=e[t];return Ue.isValidElementType(a)?null:new i("Invalid "+r+" `"+o+"` of type `"+s(a)+"` supplied to `"+n+"`, expected a single ReactElement type.")}),instanceOf:function(e){return a(function(t,n,r,o,a){var l;return t[n]instanceof e?null:new i("Invalid "+o+" `"+a+"` of type `"+((l=t[n]).constructor&&l.constructor.name?l.constructor.name:"<<anonymous>>")+"` supplied to `"+r+"`, expected instance of `"+(e.name||"<<anonymous>>")+"`.")})},node:a(function(e,t,n,r,o){return c(e[t])?null:new i("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")}),objectOf:function(e){return a(function(t,n,r,o,a){if("function"!=typeof e)return new i("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var l=t[n],u=s(l);if("object"!==u)return new i("Invalid "+o+" `"+a+"` of type `"+u+"` supplied to `"+r+"`, expected an object.");for(var c in l)if(Ve(l,c)){var f=e(l,c,r,o,a+"."+c,ze);if(f instanceof Error)return f}return null})},oneOf:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&Ze(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),Qe;function t(t,n,r,a,l){for(var u=t[n],c=0;c<e.length;c++)if(o(u,e[c]))return null;var s=JSON.stringify(e,function(e,t){return"symbol"===f(t)?String(t):t});return new i("Invalid "+a+" `"+l+"` of value `"+String(u)+"` supplied to `"+r+"`, expected one of "+s+".")}return a(t)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&Ze("Invalid argument supplied to oneOfType, expected an instance of array."),Qe;for(var t=0;t<e.length;t++){var n=e[t];if("function"!=typeof n)return Ze("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+d(n)+" at index "+t+"."),Qe}return a(function(t,n,r,o,a){for(var l=[],u=0;u<e.length;u++){var c=(0,e[u])(t,n,r,o,a,ze);if(null==c)return null;c.data&&Ve(c.data,"expectedType")&&l.push(c.data.expectedType)}return new i("Invalid "+o+" `"+a+"` supplied to `"+r+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")})},shape:function(e){return a(function(t,n,r,o,a){var l=t[n],c=s(l);if("object"!==c)return new i("Invalid "+o+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected `object`.");for(var d in e){var p=e[d];if("function"!=typeof p)return u(r,o,a,d,f(p));var m=p(l,d,r,o,a+"."+d,ze);if(m)return m}return null})},exact:function(e){return a(function(t,n,r,o,a){var l=t[n],c=s(l);if("object"!==c)return new i("Invalid "+o+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected `object`.");var d=$e({},t[n],e);for(var p in d){var m=e[p];if(Ve(e,p)&&"function"!=typeof m)return u(r,o,a,p,f(m));if(!m)return new i("Invalid "+o+" `"+a+"` key `"+p+"` supplied to `"+r+"`.\nBad object: "+JSON.stringify(t[n],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var v=m(l,p,r,o,a+"."+p,ze);if(v)return v}return null})}};function o(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function i(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function a(e){function t(t,n,r,o,a,l,u){if(o=o||"<<anonymous>>",l=l||r,u!==ze){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}return null==n[r]?t?new i(null===n[r]?"The "+a+" `"+l+"` is marked as required in `"+o+"`, but its value is `null`.":"The "+a+" `"+l+"` is marked as required in `"+o+"`, but its value is `undefined`."):null:e(n,r,o,a,l)}process;var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n}function l(e){return a(function(t,n,r,o,a,l){var u=t[n];return s(u)!==e?new i("Invalid "+o+" `"+a+"` of type `"+f(u)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null})}function u(e,t,n,r,o){return new i((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function c(t){switch(typeof t){case"number":case"string":case"undefined":return!0;case"boolean":return!t;case"object":if(Array.isArray(t))return t.every(c);if(null===t||e(t))return!0;var r=function(e){var t=e&&(n&&e[n]||e["@@iterator"]);if("function"==typeof t)return t}(t);if(!r)return!1;var o,i=r.call(t);if(r!==t.entries){for(;!(o=i.next()).done;)if(!c(o.value))return!1}else for(;!(o=i.next()).done;){var a=o.value;if(a&&!c(a[1]))return!1}return!0;default:return!1}}function s(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function f(e){if(null==e)return""+e;var t=s(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function d(e){var t=f(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return i.prototype=Error.prototype,r.checkPropTypes=Je,r.resetWarningCache=Je.resetWarningCache,r.PropTypes=r,r}(Ue.isElement):function(){function e(e,t,n,r,o,i){if(i!==ze){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:et,resetWarningCache:Xe};return n.PropTypes=n,n}()}),nt=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}},rt=Object.prototype.toString;function ot(e){return"[object Array]"===rt.call(e)}function it(e){return void 0===e}function at(e){return null!==e&&"object"==typeof e}function lt(e){if("[object Object]"!==rt.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function ut(e){return"[object Function]"===rt.call(e)}function ct(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),ot(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.call(null,e[o],o,e)}var st={isArray:ot,isArrayBuffer:function(e){return"[object ArrayBuffer]"===rt.call(e)},isBuffer:function(e){return null!==e&&!it(e)&&null!==e.constructor&&!it(e.constructor)&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)},isFormData:function(e){return"undefined"!=typeof FormData&&e instanceof FormData},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer},isString:function(e){return"string"==typeof e},isNumber:function(e){return"number"==typeof e},isObject:at,isPlainObject:lt,isUndefined:it,isDate:function(e){return"[object Date]"===rt.call(e)},isFile:function(e){return"[object File]"===rt.call(e)},isBlob:function(e){return"[object Blob]"===rt.call(e)},isFunction:ut,isStream:function(e){return at(e)&&ut(e.pipe)},isURLSearchParams:function(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:ct,merge:function e(){var t={};function n(n,r){t[r]=lt(t[r])&<(n)?e(t[r],n):lt(n)?e({},n):ot(n)?n.slice():n}for(var r=0,o=arguments.length;r<o;r++)ct(arguments[r],n);return t},extend:function(e,t,n){return ct(t,function(t,r){e[r]=n&&"function"==typeof t?nt(t,n):t}),e},trim:function(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e}};function ft(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var dt=function(e,t,n){if(!t)return e;var r;if(n)r=n(t);else if(st.isURLSearchParams(t))r=t.toString();else{var o=[];st.forEach(t,function(e,t){null!=e&&(st.isArray(e)?t+="[]":e=[e],st.forEach(e,function(e){st.isDate(e)?e=e.toISOString():st.isObject(e)&&(e=JSON.stringify(e)),o.push(ft(t)+"="+ft(e))}))}),r=o.join("&")}if(r){var i=e.indexOf("#");-1!==i&&(e=e.slice(0,i)),e+=(-1===e.indexOf("?")?"?":"&")+r}return e};function pt(){this.handlers=[]}pt.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},pt.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},pt.prototype.forEach=function(e){st.forEach(this.handlers,function(t){null!==t&&e(t)})};var mt=pt,vt=function(e,t,n){return st.forEach(n,function(n){e=n(e,t)}),e},ht=function(e){return!(!e||!e.__CANCEL__)},gt=function(e,t){st.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})},yt=function(e,t,n,r,o){return function(e,t,n,r,o){return e.config=t,n&&(e.code=n),e.request=r,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}(new Error(e),t,n,r,o)},_t=st.isStandardBrowserEnv()?{write:function(e,t,n,r,o,i){var a=[];a.push(e+"="+encodeURIComponent(t)),st.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),st.isString(r)&&a.push("path="+r),st.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}},Et=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"],bt=st.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function r(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=r(window.location.href),function(t){var n=st.isString(t)?r(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0},Ct={"Content-Type":"application/x-www-form-urlencoded"};function St(e,t){!st.isUndefined(e)&&st.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var Lt,Nt={adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(Lt=function(e){return new Promise(function(t,n){var r=e.data,o=e.headers;st.isFormData(r)&&delete o["Content-Type"];var i=new XMLHttpRequest;if(e.auth){var a=e.auth.username||"",l=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.Authorization="Basic "+btoa(a+":"+l)}var u,c,s=(c=e.url,(u=e.baseURL)&&!/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(c)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(u,c):c);if(i.open(e.method.toUpperCase(),dt(s,e.params,e.paramsSerializer),!0),i.timeout=e.timeout,i.onreadystatechange=function(){if(i&&4===i.readyState&&(0!==i.status||i.responseURL&&0===i.responseURL.indexOf("file:"))){var r,o,a,l,u,c="getAllResponseHeaders"in i?(r=i.getAllResponseHeaders(),u={},r?(st.forEach(r.split("\n"),function(e){if(l=e.indexOf(":"),o=st.trim(e.substr(0,l)).toLowerCase(),a=st.trim(e.substr(l+1)),o){if(u[o]&&Et.indexOf(o)>=0)return;u[o]="set-cookie"===o?(u[o]?u[o]:[]).concat([a]):u[o]?u[o]+", "+a:a}}),u):u):null;!function(e,t,n){var r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(yt("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}(t,n,{data:e.responseType&&"text"!==e.responseType?i.response:i.responseText,status:i.status,statusText:i.statusText,headers:c,config:e,request:i}),i=null}},i.onabort=function(){i&&(n(yt("Request aborted",e,"ECONNABORTED",i)),i=null)},i.onerror=function(){n(yt("Network Error",e,null,i)),i=null},i.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(yt(t,e,"ECONNABORTED",i)),i=null},st.isStandardBrowserEnv()){var f=(e.withCredentials||bt(s))&&e.xsrfCookieName?_t.read(e.xsrfCookieName):void 0;f&&(o[e.xsrfHeaderName]=f)}if("setRequestHeader"in i&&st.forEach(o,function(e,t){void 0===r&&"content-type"===t.toLowerCase()?delete o[t]:i.setRequestHeader(t,e)}),st.isUndefined(e.withCredentials)||(i.withCredentials=!!e.withCredentials),e.responseType)try{i.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&i.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&i.upload&&i.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){i&&(i.abort(),n(e),i=null)}),r||(r=null),i.send(r)})}),Lt),transformRequest:[function(e,t){return gt(t,"Accept"),gt(t,"Content-Type"),st.isFormData(e)||st.isArrayBuffer(e)||st.isBuffer(e)||st.isStream(e)||st.isFile(e)||st.isBlob(e)?e:st.isArrayBufferView(e)?e.buffer:st.isURLSearchParams(e)?(St(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):st.isObject(e)?(St(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};st.forEach(["delete","get","head"],function(e){Nt.headers[e]={}}),st.forEach(["post","put","patch"],function(e){Nt.headers[e]=st.merge(Ct)});var At=Nt;function wt(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var xt=function(e){return wt(e),e.headers=e.headers||{},e.data=vt(e.data,e.headers,e.transformRequest),e.headers=st.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),st.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]}),(e.adapter||At.adapter)(e).then(function(t){return wt(e),t.data=vt(t.data,t.headers,e.transformResponse),t},function(t){return ht(t)||(wt(e),t&&t.response&&(t.response.data=vt(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})},It=function(e,t){t=t||{};var n={},r=["url","method","data"],o=["headers","auth","proxy","params"],i=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function l(e,t){return st.isPlainObject(e)&&st.isPlainObject(t)?st.merge(e,t):st.isPlainObject(t)?st.merge({},t):st.isArray(t)?t.slice():t}function u(r){st.isUndefined(t[r])?st.isUndefined(e[r])||(n[r]=l(void 0,e[r])):n[r]=l(e[r],t[r])}st.forEach(r,function(e){st.isUndefined(t[e])||(n[e]=l(void 0,t[e]))}),st.forEach(o,u),st.forEach(i,function(r){st.isUndefined(t[r])?st.isUndefined(e[r])||(n[r]=l(void 0,e[r])):n[r]=l(void 0,t[r])}),st.forEach(a,function(r){r in t?n[r]=l(e[r],t[r]):r in e&&(n[r]=l(void 0,e[r]))});var c=r.concat(o).concat(i).concat(a),s=Object.keys(e).concat(Object.keys(t)).filter(function(e){return-1===c.indexOf(e)});return st.forEach(s,u),n};function Tt(e){this.defaults=e,this.interceptors={request:new mt,response:new mt}}Tt.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=It(this.defaults,e)).method=e.method?e.method.toLowerCase():this.defaults.method?this.defaults.method.toLowerCase():"get";var t=[xt,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},Tt.prototype.getUri=function(e){return e=It(this.defaults,e),dt(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},st.forEach(["delete","get","head","options"],function(e){Tt.prototype[e]=function(t,n){return this.request(It(n||{},{method:e,url:t,data:(n||{}).data}))}}),st.forEach(["post","put","patch"],function(e){Tt.prototype[e]=function(t,n,r){return this.request(It(r||{},{method:e,url:t,data:n}))}});var Dt=Tt;function Ot(e){this.message=e}Ot.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},Ot.prototype.__CANCEL__=!0;var Rt=Ot;function Pt(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new Rt(e),t(n.reason))})}Pt.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},Pt.source=function(){var e;return{token:new Pt(function(t){e=t}),cancel:e}};var kt=Pt;function Bt(e){var t=new Dt(e),n=nt(Dt.prototype.request,t);return st.extend(n,Dt.prototype,t),st.extend(n,t),n}var Ut=Bt(At);Ut.Axios=Dt,Ut.create=function(e){return Bt(It(Ut.defaults,e))},Ut.Cancel=Rt,Ut.CancelToken=kt,Ut.isCancel=ht,Ut.all=function(e){return Promise.all(e)},Ut.spread=function(e){return function(t){return e.apply(null,t)}},Ut.isAxiosError=function(e){return"object"==typeof e&&!0===e.isAxiosError};var Mt=Ut;Mt.default=Ut;var jt=Mt;const Ft=e=>{var n,a,l,u;let{template:c,header:s,actionButtonLabel:f}=e;const{t:d}=o.useTranslation(),p=i.useHistory(),m={},v=Digit.UserService.getUser(),h=null==v||null===(n=v.info)||void 0===n?void 0:n.tenantId;m.mobileNumber=null==v||null===(a=v.info)||void 0===a?void 0:a.mobileNumber;const g=Digit.Hooks.mcollect.useMcollectSearchBill({tenantId:h,filters:m}),y=null==g||null===(l=g.data)||void 0===l||null===(u=l.Bills)||void 0===u?void 0:u.map(e=>{return{businesService:e.businessService,total_due:"ACTIVE"===e.status?e.totalAmount:0,OwnerName:e.payerName||d("CS_NA"),BillingPeriod:(t=e.billDetails[0].fromPeriod,n=e.billDetails[0].toPeriod,t&&n?new Date(t).getDate()+" "+Digit.Utils.date.monthNames[new Date(t).getMonth()]+" "+new Date(t).getFullYear()+" - "+new Date(n).getDate()+" "+Digit.Utils.date.monthNames[new Date(n).getMonth()]+" "+new Date(n).getFullYear():"N/A"),bil_due__date:new Date(e.billDetails[0].expiryDate).getDate().toString()+"/"+(new Date(e.billDetails[0].expiryDate).getMonth()+1).toString()+"/"+new Date(e.billDetails[0].expiryDate).getFullYear().toString(),ChannelNo:(null==e?void 0:e.consumerCode)||d("CS_NA"),ServiceCategory:e.businessService?e.businessService.split(".")[e.businessService.split(".").length-1]:d("CS_NA")};var t,n});return r.createElement("div",{style:{marginTop:"16px"}},r.createElement("div",null,s&&r.createElement(t.Header,{style:{marginLeft:"8px"}},d(s)," (",null==y?void 0:y.length,")"),r.createElement("div",null,r.createElement(t.ResponseComposer,{data:y,template:c,actionButtonLabel:f,onSubmit:e=>{p.push(`/digit-ui/citizen/payment/my-bills/${null==e?void 0:e.businesService}/${null==e?void 0:e.ChannelNo}?workflow=mcollect`)}}))),r.createElement("div",{style:{marginLeft:"16px",marginTop:"16px",marginBottom:"46px"}},r.createElement("p",null,d("UC_NOT_ABLE_TO_FIND_BILL_MSG")," "),r.createElement("p",{className:"link"},r.createElement(i.Link,{to:"/digit-ui/citizen/mcollect/search"},d("UC_CLICK_HERE_TO_SEARCH_LINK")))))};Ft.propTypes={template:tt.any,header:tt.string,actionButtonLabel:tt.string},Ft.defaultProps={template:[],header:null,actionButtonLabel:null};const Ht=[{texts:{header:"UC_SEARCH_CHALLAN_LABEL",submitBarLabel:"UC_SEARCH_LABEL",cardText:"UC_HOME_SEARCH_RESULTS_DESC"},inputs:[{label:"UC_SEARCH_MOBILE_NO_LABEL",type:"mobileNumber",name:"mobileNumber",error:"CORE_COMMON_PHONENO_INVALIDMSG"},{label:"UC_CHALLAN_NO",type:"number",name:"ChallanNo",error:"UC_WRONG_CHALLAN_NO"},{label:"UC_SERVICE_CATEGORY_LABEL",type:"any",name:"ServiceCategory",error:"UC_INVALID_SERVICE_CATEGORY"}]}];jt.interceptors.response.use(e=>e,e=>{var t,n;const r=window.location.pathname.split("/").includes("employee");if(null!=e&&null!==(t=e.response)&&void 0!==t&&null!==(n=t.data)&&void 0!==n&&n.Errors)for(const t of e.response.data.Errors){var o,i,a,l;t.message.includes("InvalidAccessTokenException")?(localStorage.clear(),sessionStorage.clear(),window.location.href=(r?"/digit-ui/employee/user/login":"/digit-ui/citizen/login")+"?from="+encodeURIComponent(window.location.pathname+window.location.search)):null!=t&&null!==(o=t.message)&&void 0!==o&&null!==(i=o.toLowerCase())&&void 0!==i&&i.includes("internal server error")||null!=t&&null!==(a=t.message)&&void 0!==a&&null!==(l=a.toLowerCase())&&void 0!==l&&l.includes("some error occured")?window.location.href=(r?"/digit-ui/employee/user/error":"/digit-ui/citizen/error")+"?type=maintenance&from="+encodeURIComponent(window.location.pathname+window.location.search):t.message.includes("ZuulRuntimeException")&&(window.location.href=(r?"/digit-ui/employee/user/error":"/digit-ui/citizen/error")+"?type=notfound&from="+encodeURIComponent(window.location.pathname+window.location.search))}throw e}),window.Digit=window.Digit||{},window.Digit={...window.Digit,RequestCache:window.Digit.RequestCache||{}};const $t=e=>{var a;let{config:l,formData:u}=e;const{t:c}=o.useTranslation();let s={};const f=i.useHistory(),d=Digit.ULBService.getCurrentTenantId(),[p,m]=n.useState((null==u?void 0:u.mobileNumber)||""),[v,h]=n.useState((null==u?void 0:u.challanNo)||""),[g,y]=n.useState((null==u?void 0:u.Servicecateogry)||""),[_,E]=n.useState((null==u?void 0:u.city)||""),b=null===(a=Digit.Hooks.mcollect.usemcollectTenants())||void 0===a?void 0:a.sort((e,t)=>{var n,r;return null==e||null===(n=e.i18nKey)||void 0===n||null===(r=n.localeCompare)||void 0===r?void 0:r.call(n,null==t?void 0:t.i18nKey)}),[C,S]=n.useState(null),{data:L,isLoading:A}=Digit.Hooks.mcollect.useMCollectMDMS(d,"BillingService","BusinessService");if(A)return r.createElement(t.Loader,null);let w=[];return L&&L.map(e=>{e.billGineiURL&&w.push({i18nKey:""+e.i18nKey.toUpperCase().replaceAll(".","_"),code:e.i18nKey})}),r.createElement("div",{style:{marginTop:"16px"}},r.createElement(t.FormStep,{config:l,label:l.texts.submitButtonLabel,heading:l.texts.header,text:l.texts.text,cardStyle:{margin:"auto",maxWidth:"960px"},headingStyle:{fontSize:"32px",marginBottom:"16px"},onSelect:function(e){try{return p||v||g||_?g?_.code?(f.push(`/digit-ui/citizen/mcollect/search-results?mobileNumber=${p}&challanNo=${v}&Servicecategory=${g?g.code.replace("BILLINGSERVICE_BUSINESSSERVICE_",""):""}&tenantId=${_.code}`),Promise.resolve()):Promise.resolve(alert("Please Provide City")):Promise.resolve(alert("Please Provide Service Category")):Promise.resolve(alert("Provide at least one parameter"))}catch(e){return Promise.reject(e)}},componentInFront:r.createElement("div",{className:"employee-card-input employee-card-input--front"},"+91"),isDisabled:!g||!_.code,forcedError:c(C),t:c},r.createElement(t.CardLabel,null,c("UC_CITY_LABEL")+"*"),r.createElement(t.RadioOrSelect,N({className:"form-field",isMandatory:!0,t:c,optionKey:"code",name:"City",options:b,value:_,selectedOption:_,onSelect:function(e){E(e)}},s={isRequired:!0,title:c("UC_CITY_MANDATORY")})),r.createElement(t.CardLabel,null,c("UC_SERVICE_CATEGORY_LABEL")+"*"),L&&r.createElement(t.RadioOrSelect,N({t:c,optionKey:"i18nKey",name:"Servicecategory",options:w,value:g,selectedOption:g,onSelect:function(e){y(e)}},s={isRequired:!0,title:c("please enter service category")})),r.createElement(t.CardLabel,null,""+c("UC_SEARCH_MOBILE_NO_LABEL")),r.createElement("div",{className:"field-container"},r.createElement("span",{className:"employee-card-input employee-card-input--front",style:{marginTop:"-1px"}},"+91"),r.createElement(t.TextInput,N({type:"mobileNumber",t:c,isMandatory:!1,style:{maxWidth:"500px"},optionKey:"i18nKey",name:"mobileNumber",value:p,onChange:function(e){S(null),e.target.value.match("^\\d{10}$")||S("CORE_COMMON_PHONENO_INVALIDMSG"),m(e.target.value)}},s={isRequired:!1,pattern:"[6-9]{1}[0-9]{9}",type:"tel",title:c("CORE_COMMON_APPLICANT_MOBILE_NUMBER_INVALID")}))),r.createElement(t.CardLabel,null,""+c("UC_CHALLAN_NO")),r.createElement(t.TextInput,{t:c,type:"any",isMandatory:!1,optionKey:"i18nKey",name:"ChallanNo",value:v,onChange:function(e){h(e.target.value)}})))};$t.propTypes={loginParams:tt.any},$t.defaultProps={loginParams:null};const zt=[{texts:{header:"CS_SEARCH_RESULTS",actionButtonLabel:"CS_VIEW_DETAILS"},labels:[{label:"UC_AMOUNT_DUE_LABEL",key:"total_due",noteStyle:{fontSize:"24px",fontWeight:"bold"},notePrefix:"₹ "},{label:"UC_CHALLAN_NO",key:"ChannelNo"},{label:"UC_SERVICE_CATEGORY_LABEL",key:"ServiceCategory"},{label:"UC_OWNER_NAME_LABEL",key:"OwnerName"},{label:"UC_DUE_DATE",key:"bil_due__date"}]}],Vt=e=>{var n,a;let{template:l,header:u,actionButtonLabel:c}=e;const{t:s}=o.useTranslation(),f=i.useHistory(),{mobileNumber:d,challanNo:p,Servicecategory:m,tenantId:v}=Digit.Hooks.useQueryParams(),h={};d&&(h.mobileNumber=d),p&&(h.consumerCode=p),m&&(h.businesService=m);const g=Digit.Hooks.mcollect.useMcollectSearchBill({tenantId:v,filters:h});if(g.isLoading)return r.createElement(t.Loader,null);const y=null==g||null===(n=g.data)||void 0===n||null===(a=n.Bills)||void 0===a?void 0:a.map(e=>({businesService:e.businessService,total_due:"ACTIVE"===e.status?e.totalAmount:0,OwnerName:e.payerName||s("CS_NA"),bil_due__date:new Date(e.billDetails[0].expiryDate).getDate().toString()+"/"+(new Date(e.billDetails[0].expiryDate).getMonth()+1).toString()+"/"+new Date(e.billDetails[0].expiryDate).getFullYear().toString(),ChannelNo:(null==e?void 0:e.consumerCode)||s("CS_NA"),ServiceCategory:e.businessService?e.businessService.split(".")[e.businessService.split(".").length-1]:s("CS_NA")}));return r.createElement("div",{style:{marginTop:"16px"}},r.createElement("div",null,u&&r.createElement(t.Header,{style:{marginLeft:"8px"}},s(u)," (",null==y?void 0:y.length,")"),r.createElement(t.ResponseComposer,{data:y,template:l,actionButtonLabel:c,onSubmit:e=>{f.push(`/digit-ui/citizen/payment/my-bills/${null==e?void 0:e.businesService}/${null==e?void 0:e.ChannelNo}?workflow=mcollect`)}})))};Vt.propTypes={template:tt.any,header:tt.string,actionButtonLabel:tt.string},Vt.defaultProps={template:[],header:null,actionButtonLabel:null};const Wt=function(){function e(){}return e.prototype.then=function(t,n){const r=new e,o=this.s;if(o){const e=1&o?t:n;if(e){try{qt(r,1,e(this.v))}catch(e){qt(r,2,e)}return r}return this}return this.o=function(e){try{const o=e.v;1&e.s?qt(r,1,t?t(o):o):n?qt(r,1,n(o)):qt(r,2,o)}catch(e){qt(r,2,e)}},r},e}();function qt(e,t,n){if(!e.s){if(n instanceof Wt){if(!n.s)return void(n.o=qt.bind(null,e,t));1&t&&(t=n.s),n=n.v}if(n&&n.then)return void n.then(qt.bind(null,e,t),qt.bind(null,e,2));e.s=t,e.v=n;const r=e.o;r&&r(e)}}"undefined"!=typeof Symbol&&(Symbol.iterator||(Symbol.iterator=Symbol("Symbol.iterator"))),"undefined"!=typeof Symbol&&(Symbol.asyncIterator||(Symbol.asyncIterator=Symbol("Symbol.asyncIterator")));const Gt=e=>{let{t:n,currentPage:o,columns:i,data:a,getCellProps:l,disableSort:u,onSort:c,onNextPage:s,onPrevPage:f,onFirstPage:d,onLastPage:p,onPageSizeChange:m,pageSizeLimit:v,sortParams:h,totalRecords:g,isPaginationRequired:y}=e;return r.createElement(t.Table,{t:n,data:a,currentPage:o,columns:i,getCellProps:l,onNextPage:s,onPrevPage:f,onLastPage:p,onFirstPage:d,pageSizeLimit:v,disableSort:u,onPageSizeChange:m,onSort:c,sortParams:h,totalRecords:g,isPaginationRequired:y})},Kt=e=>{const{t:a}=o.useTranslation(),[l,u]=n.useState([]),c=[{text:a("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application",roles:[]}];return n.useEffect(()=>{u(c)},[]),r.createElement(t.Card,{style:{paddingRight:0,marginTop:0},className:"employeeCard filter inboxLinks"},r.createElement("div",{className:"complaint-links-container"},r.createElement("div",{className:"header",style:{justifyContent:"flex-start"}},r.createElement("span",{className:"logo"},r.createElement(t.PTIcon,null))," ",r.createElement("span",{className:"text"},a("UC_COMMON_HEADER_SEARCH"))),r.createElement("div",{className:"body"},l.map((e,t)=>{let{link:n,text:o,hyperlink:l=!1,accessTo:u=[]}=e;return r.createElement("span",{className:"link",key:t},l?r.createElement("a",{href:n},a(o)):r.createElement(i.Link,{to:n},a(o)))}))))},Yt=e=>{var n;let{onSearch:i,type:l,onClose:u,searchFields:c,searchParams:s,isInboxPage:f}=e;const{t:d}=o.useTranslation(),{register:p,handleSubmit:m,reset:v,watch:h,control:g}=a.useForm({defaultValues:s}),y=innerWidth<=640;function _(){const e=c.reduce((e,t)=>({...e,[null==t?void 0:t.name]:""}),{});v(e);const t={...s};t.delete=[],c.forEach(e=>{t.delete.push(null==e?void 0:e.name)}),i({...t})}const E=e=>r.createElement(t.LinkLabel,{style:{display:"inline",...e?{margin:0}:{}},onClick:_},d("UC_CLEAR_SEARCH_LABEL"));return r.createElement("form",{onSubmit:m(e=>{e.mobileNumber||delete e.mobileNumber,e.delete=[],c.forEach(t=>{e[t.name]||e.delete.push(t.name)}),i(e),"mobile"===l&&u()})},r.createElement(r.Fragment,null,r.createElement("div",{className:"search-container",style:{width:"auto",marginLeft:f?"24px":"revert"}},r.createElement("div",{className:"search-complaint-container"},("mobile"===l||y)&&r.createElement("div",{className:"complaint-header"},r.createElement("h2",null,d("ES_COMMON_SEARCH_BY")),r.createElement("span",{onClick:u},r.createElement(t.CloseSvg,null))),r.createElement("div",{className:"complaint-input-container for-pt "+("desktop"!==l||y?"for-search":""),style:{width:"100%",display:"grid"}},null==c||null===(n=c.filter(e=>!0))||void 0===n?void 0:n.map((e,n)=>r.createElement("div",{key:e.name,className:"input-fields"},r.createElement("span",{key:n,className:"complaint-input"}," ",r.createElement(t.Label,null,e.label),"date"!==e.type?r.createElement("div",{className:"field-container"},null!=e&&e.componentInFront?r.createElement("span",{className:"citizen-card-input citizen-card-input--front",style:{flex:"none"}},null==e?void 0:e.componentInFront):null,r.createElement(t.TextInput,N({},e,{inputRef:p,watch:h,shouldUpdate:!0}))):r.createElement(a.Controller,{render:e=>r.createElement(t.DatePicker,{date:e.value,onChange:e.onChange}),name:e.name,control:g,defaultValue:null})," "))),"desktop"===l&&!y&&r.createElement("div",{style:{gridColumn:"2/3",textAlign:"right",paddingTop:"10px"},className:"input-fields"},r.createElement("div",null,E())),"desktop"===l&&!y&&r.createElement("div",{style:{maxWidth:"unset",marginLeft:"unset"},className:"search-submit-wrapper"},r.createElement(t.SubmitBar,{className:"submit-bar-search",label:d("UC_SEARCH_LABEL"),submit:!0}),!f&&r.createElement("div",null,E()))))),("mobile"===l||y)&&r.createElement(t.ActionBar,{className:"clear-search-container"},r.createElement("button",{className:"clear-search",style:{flex:1}},E(y)),r.createElement(t.SubmitBar,{label:d("UC_SEARCH_LABEL"),style:{flex:1},submit:!0}))))},Jt=e=>{let{filterComponent:a,...l}=e;const{data:u}=l,{t:c}=o.useTranslation(),[s,f]=n.useState(()=>{var e;return null===(e=Digit.ComponentRegistryService)||void 0===e?void 0:e.getComponent(a)}),d=e=>r.createElement("span",{className:"cell-text"},e),p=e=>{if(null==e||null==e||""==e)return"NA";const t=new Date(e);let n=t.getMonth()+1,r=t.getDate();return n=(n>9?"":"0")+n,r=(r>9?"":"0")+r,`${r}/${n}/${t.getFullYear()}`},m=e=>r.createElement("span",{className:"sla-cell"},e);let v;return l.isLoading||l.isLoader?v=r.createElement(t.Loader,null):0===(null==u?void 0:u.length)?v=r.createElement(t.Card,{style:{marginTop:20}},c("CS_MYAPPLICATIONS_NO_APPLICATION").split("\\n").map((e,t)=>r.createElement("p",{key:t,style:{textAlign:"center"}},e))):(null==u?void 0:u.length)>0&&(v=r.createElement(Gt,{t:c,data:u,columns:[{Header:c("UC_CHALLAN_NUMBER"),Cell:e=>{var t,n;let{row:o}=e;return r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:l.parentRoute+"/challansearch/"+(null===(t=o.original)||void 0===t?void 0:t.challanNo)},null===(n=o.original)||void 0===n?void 0:n.challanNo)))},mobileCell:e=>m(null==e?void 0:e.challanNo)},{Header:c("UC_COMMON_TABLE_COL_PAYEE_NAME"),Cell:e=>{var t;let{row:n}=e;return d(""+(null===(t=n.original)||void 0===t?void 0:t.name))},mobileCell:e=>m(null==e?void 0:e.name)},{Header:c("UC_SERVICE_CATEGORY_LABEL"),Cell:e=>{var t;let{row:n}=e,r=function(e,t,n){if(void 0===e&&(e=""),void 0===t&&(t=""),void 0===n&&(n=""),""==t)return e;for(;e.includes(t);)e=e.replace(t,n);return e}(""+(null===(t=n.original)||void 0===t?void 0:t.businessService),".","_");return r=r.toUpperCase(),d(c("BILLINGSERVICE_BUSINESSSERVICE_"+r))},mobileCell:e=>m("BILLINGSERVICE_BUSINESSSERVICE_"+(null==e?void 0:e.businessService))},{Header:c("UC_RECIEPT_NUMBER_LABEL"),Cell:e=>{var t,n;let{row:r}=e;return null!==(t=r.original)&&void 0!==t&&t.receiptNumber?d(""+(null===(n=r.original)||void 0===n?void 0:n.receiptNumber)):"-"},mobileCell:e=>m(null==e?void 0:e.receiptNumber)||"-"},{Header:c("UC_DUE_DATE"),Cell:e=>{var t,n;let{row:r}=e;const o="NA"===(null===(t=r.original)||void 0===t?void 0:t.dueDate)?c("CS_NA"):p(null===(n=r.original)||void 0===n?void 0:n.dueDate);return d(c(""+o))},mobileCell:e=>m(p(null==e?void 0:e.dueDate))},{Header:c("UC_TOTAL_AMOUNT"),Cell:e=>{var t;let{row:n}=e;return d(c(""+(null===(t=n.original)||void 0===t?void 0:t.totalAmount)))},mobileCell:e=>m(null==e?void 0:e.totalAmount)},{Header:c("UC_COMMON_TABLE_COL_STATUS"),Cell:e=>{var t;let{row:n}=e;return d(c(""+(null===(t=n.original)||void 0===t?void 0:t.applicationStatus)))},mobileCell:e=>{var t,n;return m(null==e||null===(t=e.workflowData)||void 0===t||null===(n=t.state)||void 0===n?void 0:n.state)}},{Header:c("UC_TABLE_COL_ACTION"),Cell:e=>{var t,n;let{row:a}=e,l="ACTIVE";var u,s,f,p,m;return(null===(t=a.original)||void 0===t?void 0:t.totalAmount)>0&&(l="COLLECT"),"COLLECT"==l?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null===(u=a.original)||void 0===u?void 0:u.businessService}/${null===(s=a.original)||void 0===s?void 0:s.challanNo}/tenantId=${null===(f=a.original)||void 0===f?void 0:f.tenantId}?workflow=mcollect`}},c("UC_"+l)))):"PAID"==(null===(n=a.original)||void 0===n?void 0:n.applicationStatus)?r.createElement("div",null,r.createElement("span",{className:"link"},((e,t)=>{const{t:n}=o.useTranslation();return r.createElement("a",{href:"javascript:void(0)",style:{color:"#FE7A51",cursor:"pointer"},onClick:n=>{y(e,t)}}," ",n("UC_DOWNLOAD_RECEIPT")," ")})(null===(p=a.original)||void 0===p?void 0:p.businessService,null===(m=a.original)||void 0===m?void 0:m.challanNo))):d(c("CS_NA"))},mobileCell:e=>{var t,n;return m(null==e||null===(t=e.workflowData)||void 0===t||null===(n=t.state)||void 0===n?void 0:n.state)}}],getCellProps:e=>({style:{minWidth:e.column.Header===c("ES_INBOX_APPLICATION_NO")?"240px":"",padding:"20px 18px",fontSize:"16px",wordBreak:"break-word",overflowWrap:"break-word",width:"250px"}}),onPageSizeChange:l.onPageSizeChange,currentPage:l.currentPage,onNextPage:l.onNextPage,onPrevPage:l.onPrevPage,onLastPage:l.onLastPage,onFirstPage:l.onFirstPage,pageSizeLimit:l.pageSizeLimit,onSort:l.onSort,disableSort:l.disableSort,sortParams:l.sortParams,totalRecords:l.totalRecords})),r.createElement("div",{className:"inbox-container",style:{overflow:"auto"}},!l.isSearch&&r.createElement("div",{className:"filters-container"},r.createElement(Kt,{parentRoute:l.parentRoute,businessService:l.businessService}),r.createElement("div",null,r.createElement(s,{defaultSearchParams:l.defaultSearchParams,onFilterChange:l.onFilterChange,searchParams:l.searchParams,type:"desktop"}))),r.createElement("div",{style:{flex:1}},r.createElement(Yt,{defaultSearchParams:l.defaultSearchParams,onSearch:l.onSearch,type:"desktop",searchFields:l.searchFields,isInboxPage:!(null!=l&&l.isSearch),searchParams:l.searchParams}),r.createElement("div",{className:"result",style:{marginLeft:null!=l&&l.isSearch?"":"24px",flex:1}},v)))},Zt=e=>{let{t:o,data:i,defaultSearchParams:a={},onFilterChange:l,onSearch:u,serviceRequestIdKey:c,isFstpOperator:s,isLoading:f,isSearch:d,searchParams:p,searchFields:m,sortParams:v,linkPrefix:h,filterComponent:g}=e;const[y,_]=n.useState(d?"SEARCH":""),[E,b]=n.useState(!!d),[C,S]=n.useState(v),[L]=n.useState(()=>{var e;return null===(e=Digit.ComponentRegistryService)||void 0===e?void 0:e.getComponent(g)}),[N,A]=n.useState(p);n.useEffect(()=>{y&&b(!0)},[y]);const w=()=>{b(!1),_(""),S(v)};if(f)return r.createElement(t.Loader,null);let x;return i&&0!==(null==i?void 0:i.length)?i&&(null==i?void 0:i.length)>0&&(x=r.createElement(t.DetailsCard,{data:i,serviceRequestIdKey:c,linkPrefix:h||"/digit-ui/employee/mcollect/challansearch/"})):x=r.createElement(t.Card,{style:{marginTop:20}},o("CS_MYAPPLICATIONS_NO_APPLICATION").split("\\n").map((e,t)=>r.createElement("p",{key:t,style:{textAlign:"center"}},e))),r.createElement(r.Fragment,null,r.createElement("div",{className:"searchBox"},u&&r.createElement(t.SearchAction,{text:"SEARCH",handleActionClick:()=>{_("SEARCH"),A({businessService:[],status:[]}),b(!0)}}),!d&&l&&r.createElement(t.FilterAction,{text:"FILTER",handleActionClick:()=>{_("FILTER"),A({businessService:[],status:[]}),b(!0)}})),x,E&&r.createElement(t.PopUp,null,"FILTER"===y&&r.createElement("div",{className:"popup-module"},r.createElement(L,{onFilterChange:e=>{l(e,!0),b(!1)},onRefresh:l,Close:w,type:"mobile",searchParams:N,defaultSearchParams:a})),"SEARCH"===y&&r.createElement("div",{className:"popup-module"},r.createElement(Yt,{type:"mobile",onClose:w,onSearch:u,isFstpOperator:s,searchParams:N,searchFields:m}))))},Qt=e=>{let{businessService:a,allLinks:l,headerText:u}=e;const{t:c}=o.useTranslation(),[s,f]=n.useState([]),{roles:d}=Digit.UserService.getUser().info;return n.useEffect(()=>{let e=l?l.filter(e=>e.businessService===a).filter(e=>{let{roles:t}=e;return t.some(e=>d.map(e=>{let{code:t}=e;return t}).includes(e))||!t.length}):[];f(e)},[]),r.createElement(t.Card,{style:{paddingRight:0,marginTop:0},className:"employeeCard filter"},r.createElement("div",{className:"complaint-links-container"},r.createElement("div",{className:"header",style:{justifyContent:"flex-start"}},r.createElement("span",{className:"logo"},r.createElement(t.ShippingTruck,null))," ",r.createElement("span",{className:"text"},c(u))),r.createElement("div",{className:"body"},s.map((e,t)=>{let{link:n,text:o,hyperlink:a=!1,accessTo:l=[]}=e;return r.createElement("span",{className:"link",key:t},a?r.createElement("a",{href:n},c(o)):r.createElement(i.Link,{to:n},c(o)))}))))},Xt=e=>{let{data:t,defaultSearchParams:n={},isLoading:a,isSearch:l,searchFields:u,onFilterChange:c,onSearch:s,onSort:f,parentRoute:d,searchParams:p,sortParams:m,linkPrefix:v,filterComponent:h}=e;const{t:g}=o.useTranslation(),y=e=>r.createElement("span",{className:"sla-cell"},e);return r.createElement("div",{style:{padding:0}},r.createElement("div",{className:"inbox-container"},r.createElement("div",{className:"filters-container"},!l&&r.createElement(Qt,{linkPrefix:d,allLinks:[{text:g("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application",roles:[]}],headerText:g("ACTION_TEST_MCOLLECT"),isMobile:!0}),r.createElement(Zt,{t:g,data:null==t?void 0:t.map(e=>{const t={};return[{Header:g("UC_CHALLAN_NUMBER"),mobileCell:e=>y(null==e?void 0:e.challanNo)},{Header:g("UC_COMMON_TABLE_COL_PAYEE_NAME"),mobileCell:e=>y(null==e?void 0:e.name)},{Header:g("UC_SERVICE_CATEGORY_LABEL"),mobileCell:e=>{let t=function(e,t,n){if(void 0===e&&(e=""),void 0===t&&(t=""),void 0===n&&(n=""),""==t)return e;for(;e.includes(t);)e=e.replace(t,n);return e}(""+(null==e?void 0:e.businessService),".","_");return t=t.toUpperCase(),y(g("BILLINGSERVICE_BUSINESSSERVICE_"+t))}},{Header:g("UC_DUE_DATE"),mobileCell:e=>y("NA"===(null==e?void 0:e.dueDate)?g("CS_NA"):(e=>{if(null==e||null==e||""==e)return"NA";const t=new Date(e);let n=t.getMonth()+1,r=t.getDate();return n=(n>9?"":"0")+n,r=(r>9?"":"0")+r,`${r}/${n}/${t.getFullYear()}`})(null==e?void 0:e.dueDate))},{Header:g("UC_RECIEPT_NUMBER_LABEL"),mobileCell:e=>y(null===(null==e?void 0:e.receiptNumber)?g("CS_NA"):null==e?void 0:e.receiptNumber)},{Header:g("UC_TOTAL_AMOUNT"),mobileCell:e=>y(null==e?void 0:e.totalAmount)},{Header:g("UC_COMMON_TABLE_COL_STATUS"),mobileCell:e=>y(null==e?void 0:e.applicationStatus)},{Header:g("UC_TABLE_COL_ACTION"),mobileCell:e=>{let t="ACTIVE";return(null==e?void 0:e.totalAmount)>0&&(t="COLLECT"),"COLLECT"==t?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null==e?void 0:e.businessService}/${null==e?void 0:e.challanNo}/tenantId=${null==e?void 0:e.tenantId}?workflow=mcollect`}},g("UC_"+t)))):"PAID"==(null==e?void 0:e.applicationStatus)?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,null,r.createElement("a",{href:"javascript:void(0)",style:{color:"#FE7A51",cursor:"pointer"},onClick:t=>{!function(e,t){try{const n=Digit.ULBService.getCurrentTenantId(),r=Digit.ULBService.getStateId();Promise.resolve(Digit.PaymentService.getReciept(n,e,{consumerCodes:t})).then(function(e){var t;function n(){return Promise.resolve(Digit.PaymentService.printReciept(r,{fileStoreIds:o.filestoreIds[0]})).then(function(e){window.open(e[o.filestoreIds[0]],"_blank")})}let o={filestoreIds:[null===(t=e.Payments[0])||void 0===t?void 0:t.fileStoreId]};const i=function(t){if(null===(t=e.Payments[0])||void 0===t||!t.fileStoreId)return Promise.resolve(Digit.PaymentService.generatePdf(r,{Payments:e.Payments},"consolidatedreceipt")).then(function(e){o=e})}();return i&&i.then?i.then(n):n()})}catch(e){return Promise.reject(e)}}(null==e?void 0:e.businessService,null==e?void 0:e.challanNo)}}," ",g("UC_DOWNLOAD_RECEIPT")," ")))):y(g("CS_NA"))}}].forEach(n=>{n.mobileCell&&(t[n.Header]=n.mobileCell(e))}),t}),defaultSearchParams:n,onFilterChange:c,isLoading:a,isSearch:l,onSearch:s,onSort:f,searchParams:p,searchFields:u,linkPrefix:v,sortParams:m,serviceRequestIdKey:e=>{var t,n;return null==e||null===(t=e[g("UC_CHALLAN_NUMBER")])||void 0===t||null===(n=t.props)||void 0===n?void 0:n.children},filterComponent:h}))))},en=e=>{var i,a,l,u,c,s;let{parentRoute:f,businessService:d="PT",initialStates:p={},filterComponent:m,isInbox:v}=e;const h=Digit.ULBService.getCurrentTenantId();let g=Digit.SessionStorage.get("isMcollectAppChanged");const{t:y}=o.useTranslation(),[_,E]=n.useState(p.pageOffset||0),[b,C]=n.useState(p.pageSize||10),[S,L]=n.useState(p.sortParams||[{id:"createdTime",desc:!1}]),[N,A]=(Digit.Hooks.mcollect.useMCollectCount(h),n.useState(()=>p.searchParams||{})),[w,x]=n.useState({}),[I,T]=n.useState(!0);let D=window.Digit.Utils.browser.isMobile(),O=D?{limit:100,offset:0,sortOrder:null!=S&&null!==(i=S[0])&&void 0!==i&&i.desc?"DESC":"ASC"}:{limit:b,offset:_,sortOrder:null!=S&&null!==(a=S[0])&&void 0!==a&&a.desc?"DESC":"ASC"};const{isLoading:R,data:P,...k}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:h,filters:{...N,...O},isMcollectAppChanged:g});console.log("mcollect data: ",P),console.log("hookloading",R),console.log("data challan",(null==P||null===(l=P.challans)||void 0===l?void 0:l.length)>0),console.log(!R&&(null==P||null===(u=P.challans)||void 0===u?void 0:u.length)>0),n.useEffect(()=>{var e,t;!R&&!(null!=P&&null!==(e=P.challans)&&void 0!==e&&e.length)>0?T(!1):(R||null!=P&&null!==(t=P.challans)&&void 0!==t&&t.length)&&T(!0)},[R,P]),console.log("isLoader",I);let B,U=[],M={};n.useEffect(()=>{var e;null!=P&&P.challans&&(null==P||null===(e=P.challans)||void 0===e?void 0:e.length)>0&&(T(!0),function(){try{var e;function t(){T(!1),x(M)}let n={},r=[],o=[];null==P||null===(e=P.challans)||void 0===e||e.forEach(e=>{o=n[e.businessService]||[],r=o,"ADVT.Canopy_Fee"!==e.businessService&&(o.push(e.challanNo),n[e.businessService]=o)});let i=[];const a=function(e,t,r){var o=[];for(var a in e)o.push(a);return function(e,t,n){var r,o,i=-1;return function n(a){try{for(;++i<e.length;)if((a=t(i))&&a.then){if(!((l=a)instanceof Wt&&1&l.s))return void a.then(n,o||(o=qt.bind(null,r=new Wt,2)));a=a.v}r?qt(r,1,a):r=a}catch(e){qt(r||(r=new Wt),2,e)}var l}(),r}(o,function(e){return function(e){let t=n[e].toString();return Promise.resolve(Digit.PaymentService.fetchBill(h,{consumerCode:t,businessService:e})).then(function(e){B=e,i=i.concat(B.Bill),M={},i.filter(e=>null==e?void 0:e.businessService).forEach(e=>{var t,n;M[null==e?void 0:e.consumerCode]={businessService:null==e?void 0:e.businessService,otalAmount:(null==e||null===(t=e.billDetails[0])||void 0===t?void 0:t.totalAmount)||0,dueDate:null==e||null===(n=e.billDetails[0])||void 0===n?void 0:n.expiryDate}})})}(o[e])})}(n);Promise.resolve(a&&a.then?a.then(t):t())}catch(e){return Promise.reject(e)}}())},[P]),console.log("isLoader 2",I),null==P||null===(c=P.challans)||void 0===c||c.map(e=>{var t,n,r;U.push({challanNo:null==e?void 0:e.challanNo,name:null==e||null===(t=e.citizen)||void 0===t?void 0:t.name,applicationStatus:null==e?void 0:e.applicationStatus,businessService:null==e?void 0:e.businessService,totalAmount:(null===(n=w[e.challanNo])||void 0===n?void 0:n.totalAmount)||0,dueDate:(null===(r=w[e.challanNo])||void 0===r?void 0:r.dueDate)||"NA",tenantId:null==e?void 0:e.tenantId,receiptNumber:null==e?void 0:e.receiptNumber})}),n.useEffect(()=>{E(0)},[N]);const j=e=>{let t=e.delete,n={};n=D?{...e}:{...N,...e},t&&t.forEach(e=>delete n[e]),delete n.delete,delete e.delete,A({...n})},F=n.useCallback(e=>{0!==e.length&&L(e)},[]),H=()=>[{label:y("UC_CHALLAN_NUMBER"),name:"challanNo"},{label:y("UC_MOBILE_NUMBER_LABEL"),name:"mobileNumber",maxlength:10,pattern:"[6-9][0-9]{9}",title:y("ES_SEARCH_APPLICATION_MOBILE_INVALID"),componentInFront:"+91"},{label:y("UC_RECIEPT_NUMBER_LABEL"),name:"receiptNumber"}];if(null!==(null==k||null===(s=k.data)||void 0===s?void 0:s.length))return D?r.createElement(Xt,{data:U,defaultSearchParams:p.searchParams,isLoading:R,isSearch:!v,searchFields:H(),onFilterChange:j,onSearch:j,onSort:F,parentRoute:f,searchParams:N,sortParams:S,tableConfig:null==k?void 0:k.tableConfig,filterComponent:m}):r.createElement("div",null,v&&r.createElement(t.Header,null,y("UC_SEARCH_MCOLLECT_HEADER")),r.createElement(Jt,{businessService:d,data:U,tableConfig:null==k?void 0:k.tableConfig,isLoading:R,defaultSearchParams:p.searchParams,isSearch:!v,onFilterChange:j,searchFields:H(),onSearch:j,onSort:F,onNextPage:()=>{E(e=>e+b)},onPrevPage:()=>{E(e=>e-b)},onLastPage:()=>{E((null==P?void 0:P.totalCount)&&10*Math.ceil((null==P?void 0:P.totalCount)/10)-b)},onFirstPage:()=>{E(e=>0)},currentPage:Math.floor(_/b),pageSizeLimit:b,disableSort:!1,onPageSizeChange:e=>{C(Number(e.target.value))},parentRoute:f,searchParams:N,sortParams:S,totalRecords:null==P?void 0:P.totalCount,filterComponent:m,isLoader:I}))},tn=e=>{var n,a,l,u,c,s,f,d;let{path:p,url:m,userType:v}=e;const{t:h}=o.useTranslation(),g=i.useLocation(),y=innerWidth<=640,_={searchParams:{status:[],businessService:[]}},E=[{combineTaxDueInSearchData:function(e,t,n){try{function r(){return n(t)}let t;const o=Digit.ULBService.getCurrentTenantId();let i=["PT"].join(),a=e.map(e=>e.propertyId).join();const l=function(n,r){try{var l=Promise.resolve(Digit.PaymentService.fetchBill(o,{consumerCode:a,businessService:i})).then(function(n){let r={};n.Bill.forEach(e=>{r[e.consumerCode]=e.totalAmount}),t=e.map(e=>({...e,due_tax:"₹ "+(r[e.propertyId]||0)}))})}catch(e){return r(e)}return l&&l.then?l.then(void 0,r):l}(0,function(n){var r,o;const i=null==n||null===(r=n.response)||void 0===r?void 0:r.data;["EG_BS_BILL_NO_DEMANDS_FOUND","EMPTY_DEMANDS"].includes(null==i||null===(o=i.Errors)||void 0===o?void 0:o[0].code)&&(t=e.map(e=>({...e,due_tax:"₹ 0"})))});return Promise.resolve(l&&l.then?l.then(r):r())}catch(e){return Promise.reject(e)}}}],b=null===(n=Digit)||void 0===n||null===(a=n.ComponentRegistryService)||void 0===a?void 0:a.getComponent("MCollectEmployeeChallan"),C=null===(l=Digit)||void 0===l||null===(u=l.ComponentRegistryService)||void 0===u?void 0:u.getComponent("MCollectAcknowledgement"),S=null===(c=Digit)||void 0===c||null===(s=c.ComponentRegistryService)||void 0===s?void 0:s.getComponent("MCollectEditChallan"),L=null===(f=Digit)||void 0===f||null===(d=f.ComponentRegistryService)||void 0===d?void 0:d.getComponent("MCollectNewChallan");return r.createElement(i.Switch,null,r.createElement(r.Fragment,null,r.createElement("div",{className:"ground-container"},r.createElement("p",{className:"breadcrumb employee-main-application-details",style:{marginLeft:y?"2vw":"revert"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{cursor:"pointer",color:"#666"}},h("ES_COMMON_HOME"))," ","/ ",r.createElement("span",null,h("/digit-ui/employee/mcollect/inbox"===g.pathname?"UC_SEARCH_HEADER":"UC_COMMON_HEADER_SEARCH"))),r.createElement(t.PrivateRoute,{exact:!0,path:p+"/",component:()=>r.createElement(ln,{matchPath:p,userType:v})}),r.createElement(t.PrivateRoute,{path:p+"/inbox",component:()=>r.createElement(en,{parentRoute:p,businessService:"PT",filterComponent:"MCOLLECT_INBOX_FILTER",initialStates:_,isInbox:!0})})," ",r.createElement(t.PrivateRoute,{path:p+"/new-application",component:()=>r.createElement(L,{parentUrl:m})}),r.createElement(t.PrivateRoute,{path:p+"/search",component:()=>r.createElement(en,{parentRoute:p,businessService:"PT",middlewareSearch:E,initialStates:_,isInbox:!1})}),r.createElement(t.PrivateRoute,{path:p+"/acknowledgement",component:()=>r.createElement(C,null)}),r.createElement(t.PrivateRoute,{path:p+"/challansearch/:challanno",component:()=>r.createElement(b,null)}),r.createElement(t.PrivateRoute,{path:p+"/modify-challan/:challanNo",component:()=>r.createElement(S,null)})," ")))},{forwardRef:nn}=r,rn=(nn((e,i)=>{let l=e.setFormData;const{register:u,handleSubmit:c,errors:s,setValue:f}=a.useForm(),{t:d}=o.useTranslation();n.useEffect(()=>{if(l){const e=Object.keys(l);l&&e.map(e=>f(""+e,""+(null==l[""+e]?"":l[""+e])))}},[l]),l&&(f("name",""+l.name),f("mobileNumber",""+l.mobileNumber),f("doorNo",""+l.doorNo),f("buildingName",""+l.buildingName),f("street",""+l.street),f("pincode",""+(null===l.pincode?"":l.pincode)),f("comments",""+l.comments));const p=(e,n)=>{switch(e){case"text":return r.createElement("div",{className:"field-container"},n.componentInFront?n.componentInFront:null,r.createElement(t.TextInput,N({className:"field desktop-w-full"},n,{inputRef:u(n.validation)})));case"textarea":return r.createElement(t.TextArea,N({className:"field desktop-w-full",name:n.name||""},n,{inputRef:u(n.validation)}));case"custom":return r.createElement(TaxForm,N({register:u},n,{errors:s}));default:return!1!==n.dependency?n:null}},m=n.useMemo(()=>{var n;return null===(n=e.config)||void 0===n?void 0:n.map((n,o,i)=>r.createElement(r.Fragment,{key:o},r.createElement(t.CardSectionHeader,null,n.head),n.body.map((n,o)=>{var i;return r.createElement(r.Fragment,{key:o},n.label?r.createElement(t.LabelFieldPair,null,r.createElement(t.CardLabel,null,n.label,n.isMandatory?" * ":null),r.createElement("div",{className:"field"},p(n.type,n.populators))):r.createElement("div",{className:"field"},p(n.type,n.populators)),e.errors[n.populators.name]&&(null===(i=n.populators)||void 0===i||!i.validate||s[n.populators.validate])&&r.createElement(t.CardLabelError,{style:{width:"70%",marginLeft:"30%",fontSize:"12px",marginTop:"-21px"}},n.populators.error))}),i.length-1===o?null:r.createElement(t.BreakLine,null)))},[e.config,s]),v=e.isDisabled||!1;return r.createElement("form",{onSubmit:c(function(t){e.onSubmit(t)})},r.createElement(t.Card,null,r.createElement(t.CardSubHeader,null,e.heading),m,e.children,r.createElement(t.ActionBar,null,r.createElement(t.SubmitBar,{disabled:v,label:d(e.label),submit:"submit"}))))}),[{head:"",body:[{type:"component",component:"ConsumerDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]},{head:"",body:[{type:"component",component:"AddressDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]},{head:"",body:[{type:"component",component:"ServiceDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]}]),on=e=>{var a;let{ChallanData:l}=e;const u=Digit.ULBService.getCurrentTenantId(),{t:c}=o.useTranslation(),{url:s}=i.useRouteMatch();let f=!1;s.includes("modify-challan")&&(f=!0);const[d,m]=n.useState(!1),v=i.useHistory(),[h,g,y]=Digit.Hooks.useSessionStorage("store-data",null),[_,E,b]=Digit.Hooks.useSessionStorage("EMPLOYEE_MUTATION_HAPPENED",!1),[C,S,L]=Digit.Hooks.useSessionStorage("EMPLOYEE_MUTATION_SUCCESS_DATA",{}),[N,A]=n.useState(!1),w=window.Digit.Utils.browser.isMobile(),[x,I]=n.useState(null),[T,D]=n.useState(null),O=Digit.ULBService.getStateId();let{data:R}=Digit.Hooks.mcollect.useMcollectFormConfig.getFormConfig(O,{}),P=l?l[0].auditDetails.lastModifiedTime:null;const{data:k}=l?Digit.Hooks.useFetchBillsForBuissnessService({businessService:l[0].businessService,consumerCode:l[0].challanNo},{lastModTime:P}):{};n.useEffect(()=>{if(f&&k){let e=((e,t)=>{var n,r,o,i,a,l;let u={ConsumerName:e[0].citizen.name,mobileNumber:e[0].citizen.mobileNumber,emailId:e[0].citizen.emailId,doorNo:e[0].address.doorNo,building:e[0].address.buildingName,streetName:e[0].address.street,pincode:e[0].address.pincode||"143001",mohalla:{...e[0].address.locality,i18nkey:`${p(e[0].tenantId,".","_").toUpperCase()}_ADMIN_${null===(n=e[0])||void 0===n||null===(r=n.address)||void 0===r||null===(o=r.locality)||void 0===o?void 0:o.code}`},category:{code:e[0].businessService,i18nkey:"BILLINGSERVICE_BUSINESSSERVICE_"+(null===(i=e[0])||void 0===i?void 0:i.businessService.split(".")[0].toUpperCase())},categoryType:{code:e[0].businessService,i18nkey:"BILLINGSERVICE_BUSINESSSERVICE_"+p(e[0].businessService,".","_").toUpperCase()},fromDate:e[0]?new Date(e[0].taxPeriodFrom).getFullYear().toString()+"-"+`${new Date(e[0].taxPeriodFrom).getMonth()+1<10?"0":""}${new Date(e[0].taxPeriodFrom).getMonth()+1}-`+`${new Date(e[0].taxPeriodFrom).getDate()<10?"0":""}${new Date(e[0].taxPeriodFrom).getDate()}`:null,toDate:e[0]?new Date(e[0].taxPeriodTo).getFullYear().toString()+"-"+`${new Date(e[0].taxPeriodTo).getMonth()+1<10?"0":""}${new Date(e[0].taxPeriodTo).getMonth()+1}-`+`${new Date(e[0].taxPeriodTo).getDate()<10?"0":""}${new Date(e[0].taxPeriodTo).getDate()}`:null};return u[""+(null===(a=e[0])||void 0===a?void 0:a.businessService.split(".")[0])]={},t.Bill[0].billDetails[0].billAccountDetails.length>0&&t.Bill[0].billDetails[0].billAccountDetails.map(t=>{var n;return u[""+(null===(n=e[0])||void 0===n?void 0:n.businessService.split(".")[0])][""+t.taxHeadCode.split(".")[1]]=""+t.amount}),sessionStorage.setItem("InitialTaxFeilds",JSON.stringify(u[""+(null===(l=e[0])||void 0===l?void 0:l.businessService.split(".")[0])])),u})(l,k);A(!0),sessionStorage.setItem("mcollectEditObject",JSON.stringify({consomerDetails1:[{...e}]}))}},[f,k]),n.useEffect(()=>{E(!1),L()},[]),window.onunload=function(){sessionStorage.removeItem("mcollectFormData")};let B=R||[];return R=R||rn,null===(a=R)||void 0===a||a.map(e=>{"ES_NEW_APPLICATION_PROPERTY_ASSESSMENT"!==e.head&&e.head&&B.push(e)}),B=R,r.createElement("div",null,r.createElement("div",{style:w?{}:{marginLeft:"15px"}},r.createElement(t.Header,null,c(f?"UC_UPDATE_CHALLAN":"UC_COMMON_HEADER"))),!f||JSON.parse(sessionStorage.getItem("mcollectEditObject"))||N?r.createElement(t.FormComposer,{heading:c(""),label:c("ES_COMMON_APPLICATION_SUBMIT"),config:B.map(e=>{return{...e,body:e.body.filter(e=>!e.hideInEmployee),head:(t=e.head,"ES_NEW_APPLICATION_LOCATION_DETAILS"===t?"TL_CHECK_ADDRESS":"ES_NEW_APPLICATION_OWNERSHIP_DETAILS"===t?"TL_OWNERSHIP_DETAILS_HEADER":t)};var t}),fieldStyle:{marginRight:0},onSubmit:e=>{var t,n,r,o,i,a,c,d,p,m,h,g,y,_;let E=JSON.parse(sessionStorage.getItem("mcollectFormData")),b=(e=E||(null===(t=e)||void 0===t||null===(n=t.consomerDetails1)||void 0===n?void 0:n[0]))[""+(null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0])]?Object.keys(e[""+(null===(a=e)||void 0===a||null===(c=a.category)||void 0===c||null===(d=c.code)||void 0===d?void 0:d.split(".")[0])]):[],C=e[""+(null===(p=e)||void 0===p||null===(m=p.category)||void 0===m||null===(h=m.code)||void 0===h?void 0:h.split(".")[0])]?Object.values(e[""+(null===(g=e)||void 0===g||null===(y=g.category)||void 0===y||null===(_=y.code)||void 0===_?void 0:_.split(".")[0])]):[],S={};var L,N,A,w,x,T,D,O,R,P,k,B;S=f?{accountId:l[0].accountId,citizen:l[0].citizen,applicationStatus:l[0].applicationStatus,auditDetails:l[0].auditDetails,id:l[0].id,businessService:l[0].businessService,challanNo:l[0].challanNo,consumerType:null===(L=e)||void 0===L||null===(N=L.category)||void 0===N?void 0:N.code,description:e.comments,taxPeriodFrom:Date.parse(e.fromDate),taxPeriodTo:Date.parse(e.toDate),tenantId:u,address:l[0].address,amount:b.map((t,n)=>{var r,o,i;return{taxHeadCode:`${null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0]}.${t}`,amount:C[n]?Math.round(C[n]):0}})}:{citizen:{name:e.ConsumerName,mobileNumber:e.mobileNumber,emailId:e.emailId},businessService:null===(A=e)||void 0===A||null===(w=A.categoryType)||void 0===w?void 0:w.code,consumerType:null===(x=e)||void 0===x||null===(T=x.category)||void 0===T||null===(D=T.code)||void 0===D?void 0:D.split(".")[0],description:null===(O=e)||void 0===O?void 0:O.comments,taxPeriodFrom:Date.parse(null===(R=e)||void 0===R?void 0:R.fromDate),taxPeriodTo:Date.parse(null===(P=e)||void 0===P?void 0:P.toDate),tenantId:u,address:{buildingName:e.building,doorNo:e.doorNo,street:e.streetName,locality:{code:null===(k=e)||void 0===k||null===(B=k.mohalla)||void 0===B?void 0:B.code},pincode:e.pincode},amount:b.map((t,n)=>{var r,o,i;return{taxHeadCode:`${null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0]}.${t}`,amount:C[n]?Math.round(C[n]):0}})},f?Digit.MCollectService.update({Challan:S},u).then((e,t)=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];sessionStorage.removeItem("mcollectEditObject"),Digit.SessionStorage.set("isMcollectAppChanged",t.auditDetails.lastModifiedTime),Digit.MCollectService.generateBill(t.challanNo,u,t.businessService,"challan").then(e=>{e.Bill&&e.Bill.length>0&&v.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${u}&billNumber=${e.Bill[0].billNumber}&serviceCategory=${e.Bill[0].businessService}&challanNumber=${e.Bill[0].consumerCode}&isEdit=true`,{from:s})})}}).catch(e=>{var t,n;return I({key:"error",label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})}):Digit.MCollectService.create({Challan:S},u).then((e,t)=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];sessionStorage.removeItem("mcollectFormData"),Digit.MCollectService.generateBill(t.challanNo,u,t.businessService,"challan").then(e=>{e.Bill&&e.Bill.length>0&&v.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${u}&billNumber=${e.Bill[0].billNumber}&serviceCategory=${e.Bill[0].businessService}&challanNumber=${e.Bill[0].consumerCode}`,{from:s})})}}).catch(e=>{var t,n;I({key:"error",label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})})},defaultValues:{},onFormValueChange:(e,t,n)=>{m(!Object.keys(n.errors).length)},breaklineStyle:{border:"0px"}}):r.createElement(t.Loader,null),x&&r.createElement(t.Toast,{error:"error"===(null==x?void 0:x.key),label:null==x?void 0:x.label,onClose:()=>{I(null),D(null)}}))},an=e=>{let{stateCode:n,userType:o,tenants:a}=e;const l=Digit.StoreData.getCurrentLanguage(),{isLoading:u}=Digit.Services.useStore({stateCode:n,moduleCode:"UC",language:l});if(Digit.SessionStorage.set("MCollect_TENANTS",a),u)return r.createElement(t.Loader,null);const{path:c,url:s}=i.useRouteMatch();return"employee"===o?r.createElement(tn,{path:c,url:s,userType:o}):r.createElement(de,null)},ln=e=>{let{matchPath:i}=e;const{t:a}=o.useTranslation(),[l,u,c]=Digit.Hooks.useSessionStorage("PT_CREATE_PROPERTY112",{});n.useEffect(()=>{c()},[]);const s=[{link:i+"/search",i18nKey:a("UC_SEARCH_AND_PAY")},{link:i+"/My-Challans",i18nKey:a("UC_MY_CHALLANS")}];return r.createElement(t.CitizenHomeCard,{header:a("ACTION_TEST_MCOLLECT"),links:s,Icon:()=>r.createElement(t.PTIcon,{className:"fill-path-primary-main"})})},un={ConsumerDetails:e=>{var t,a,l;let{config:u,onSelect:c,formData:s,setError:f,formState:d,clearErrors:p}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(s=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:m}=o.useTranslation(),{pathname:v}=i.useLocation(),h=v.includes("/modify-challan/"),[g,y]=n.useState((null===(t=s)||void 0===t?void 0:t.consomerDetails1)||[{ConsumerName:"",mobileNumber:"",emailId:""}]),[_,E]=n.useState({index:-1,type:""}),[b,C]=(Digit.ULBService.getCurrentTenantId(),Digit.ULBService.getStateId(),n.useState(!1)),S=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID");Digit.Hooks.mcollect.useCommonMDMS(S,"common-masters",["HierarchyType"]),n.useEffect(()=>{const e=g.map(e=>e);c(null==u?void 0:u.key,e)},[g]);const L={focusIndex:_,allOwners:g,setFocusIndex:E,formData:s,formState:d,t:m,setError:f,clearErrors:p,config:u,setconsumerDetails:y,isEdit:h,setIsErrors:C,isErrors:b,consumerDetails:g};return r.createElement(r.Fragment,null,g.map((e,t)=>r.createElement(ce,N({key:e.key,index:t,consumerdetail:e},L))))},ServiceDetails:e=>{var t,a,l,u;let{config:c,onSelect:s,formData:f,setError:d,formState:p,clearErrors:m}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(f=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:v}=o.useTranslation(),{pathname:h}=i.useLocation(),g=h.includes("/modify-challan/"),y=Digit.Hooks.mcollect.usemcollectTenants(),_=()=>(null==y?void 0:y.filter(e=>e.code===Digit.ULBService.getCurrentTenantId()))||[],[E,b]=n.useState((null===(t=f)||void 0===t?void 0:t.consomerDetails1)||[se(_)]),[C,S]=n.useState({index:-1,type:""}),L=Digit.ULBService.getCurrentTenantId(),[A,w]=(Digit.ULBService.getStateId(),n.useState(!1)),x=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID"),I=Digit.Hooks.mcollect.useCommonMDMS(x,"common-masters",["HierarchyType"]),T=I&&I.data&&I.data["common-masters"]&&I.data["common-masters"].HierarchyType&&I.data["common-masters"].HierarchyType[0],[D,O]=n.useState(""),[R,P]=n.useState(""),[k,B]=n.useState([]),{Categories:U,data:M}=Digit.Hooks.mcollect.useMCollectCategory(L,"[?(@.type=='Adhoc' && @.isActive==true)]"),{data:j}=Digit.Hooks.useBoundaryLocalities(null===(u=_()[0])||void 0===u?void 0:u.code,T&&T.code.toLowerCase(),{enabled:!!_()[0]},v),[F,H]=n.useState(j),[$,z]=n.useState(!1),[V,W]=n.useState(_()[0]?_()[0]:"");n.useEffect(()=>{H(j)},[j]),n.useEffect(()=>{const e=E.map(e=>e);s(null==c?void 0:c.key,e)},[E]);const q={focusIndex:C,allOwners:E,setFocusIndex:S,formData:f,formState:p,t:v,setError:d,clearErrors:m,config:c,setconsumerDetails:b,setSelectedLocality:P,categoriesandTypes:M,localities:F,setPincode:O,getCities:_,selectedCity:V,categoires:U,setLocalities:H,setPincodeNotValid:z,isEdit:g,setIsErrors:w,isErrors:A,TaxHeadMaster:k,setSelectedCity:W,pincode:D,cities:y,fetchedLocalities:j,consumerDetails:E};return r.createElement(r.Fragment,null,E.map((e,t)=>r.createElement(fe,N({key:e.key,index:t,consumerdetail:e},q))))},AddressDetails:e=>{var t,a,l,u;let{config:c,onSelect:s,formData:f,setError:d,formState:p,clearErrors:m}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(f=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:v}=o.useTranslation(),{pathname:h}=i.useLocation(),g=h.includes("/modify-challan/"),y=Digit.Hooks.mcollect.usemcollectTenants(),_=()=>(null==y?void 0:y.filter(e=>e.code===Digit.ULBService.getCurrentTenantId()))||[],[E,b]=n.useState((null===(t=f)||void 0===t?void 0:t.consomerDetails1)||[le(_)]),[C,S]=n.useState({index:-1,type:""}),[L,A]=(Digit.ULBService.getCurrentTenantId(),Digit.ULBService.getStateId(),n.useState(!1)),w=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID"),x=Digit.Hooks.mcollect.useCommonMDMS(w,"common-masters",["HierarchyType"]),I=x&&x.data&&x.data["common-masters"]&&x.data["common-masters"].HierarchyType&&x.data["common-masters"].HierarchyType[0],[T,D]=n.useState(""),[O,R]=n.useState(""),{data:P}=Digit.Hooks.useBoundaryLocalities(null===(u=_()[0])||void 0===u?void 0:u.code,I&&I.code.toLowerCase(),{enabled:!!_()[0]},v),[k,B]=n.useState(P),[U,M]=n.useState(!1),[j,F]=n.useState(_()[0]?_()[0]:"");n.useEffect(()=>{B(P)},[P]),n.useEffect(()=>{const e=E.map(e=>e);s(null==c?void 0:c.key,e)},[E]);const H={focusIndex:C,allOwners:E,setFocusIndex:S,formData:f,formState:p,t:v,setError:d,clearErrors:m,config:c,setconsumerDetails:b,setSelectedLocality:R,localities:k,setPincode:D,getCities:_,selectedCity:j,setLocalities:B,setPincodeNotValid:M,isEdit:g,setIsErrors:A,isErrors:L,setSelectedCity:F,pincode:T,cities:y,fetchedLocalities:P,consumerDetails:E};return r.createElement(r.Fragment,null,E.map((e,t)=>r.createElement(ue,N({key:e.key,index:t,consumerdetail:e},H))))},MCollectCard:()=>{var e;if(!Digit.Utils.mCollectAccess())return null;const{t:n}=o.useTranslation(),i=Digit.ULBService.getCurrentTenantId(),{isLoading:a,data:l,...u}=Digit.Hooks.mcollect.useMCollectCount(i),c={Icon:r.createElement(t.PTIcon,null),moduleName:n("UC_COMMON_HEADER_SEARCH"),kpis:[{count:a?"-":null==l||null===(e=l.ChallanCount)||void 0===e?void 0:e.totalChallan,label:n("TOTAL_CHALLANS")}],links:[{label:n("UC_SEARCH_CHALLAN_LABEL"),link:"/digit-ui/employee/mcollect/inbox"},{label:n("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application"}]};return r.createElement(t.EmployeeModuleCard,c)},MCollectModule:an,MCollectLinks:ln,MCollectEmployeeChallan:e=>{var a,l,u,c,s,f;const{t:d}=o.useTranslation(),{challanno:v}=i.useParams(),h=Digit.ULBService.getCurrentTenantId(),[_,E]=n.useState([]),[b,C]=n.useState(0),[S,N]=n.useState(!1),[A,w]=n.useState(!1),[x,I]=n.useState(null),T=i.useHistory(),{url:D}=i.useRouteMatch(),[O,R]=n.useState(!1),[P,k]=n.useState(null);n.useEffect(()=>{switch(x){case"CANCEL_CHALLAN":return w(!0);case"UPDATE_CHALLAN":return T.push("/digit-ui/employee/mcollect/modify-challan/"+v);case"BUTTON_PAY":return T.push(`/digit-ui/employee/payment/collect/${null==F?void 0:F.businessService}/${v}/tenantId=${h}?workflow=mcollect`)}},[x]);const B=()=>{I(null),w(!1)};let U=Digit.SessionStorage.get("isMcollectAppChanged");const{data:M,...j}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:h,filters:{challanNo:v},isMcollectAppChanged:U});var F=null==M||null===(a=M.challans)||void 0===a?void 0:a.filter(function(e){return e.challanNo===v})[0];let H=[];n.useEffect(()=>{var e;null!=M&&M.challans&&(null==M||null===(e=M.challans)||void 0===e?void 0:e.length)>0&&function(){try{var e,t;H=[],Promise.resolve(Digit.PaymentService.searchBill(h,{consumerCode:null==M||null===(e=M.challans[0])||void 0===e?void 0:e.challanNo,service:null==M||null===(t=M.challans[0])||void 0===t?void 0:t.businessService})).then(function(e){var t,n,r,o;null==e||null===(t=e.Bill[0])||void 0===t||null===(n=t.billDetails[0])||void 0===n||null===(r=n.billAccountDetails)||void 0===r||r.map(e=>{H.push(e)}),C(null==e||null===(o=e.Bill[0])||void 0===o?void 0:o.totalAmount),H&&H.map(e=>{e.taxHeadCode.includes("CGST")?e.order=3:e.taxHeadCode.includes("SGST")&&(e.order=4)}),H.sort((e,t)=>e.order-t.order),E(H)})}catch(e){return Promise.reject(e)}}()},[M]);const $={order:1,label:d("UC_CHALLAN"),onClick:()=>g(v)},z={order:2,label:d("Receipt"),onClick:()=>y(null==F?void 0:F.businessService,v)},V=["CANCEL_CHALLAN","UPDATE_CHALLAN","BUTTON_PAY"];return r.createElement(r.Fragment,null,r.createElement("div",{className:"employee-application-details",style:{marginBottom:"15px"}},r.createElement(t.Header,null,""+d("CHALLAN_DETAILS")," "),r.createElement(t.MultiLink,{className:"multilinkWrapper employee-mulitlink-main-div",onHeadClick:()=>R(!O),displayOptions:O,options:"PAID"===(null==F?void 0:F.applicationStatus)?[$,z]:[$],downloadBtnClassName:"employee-download-btn-className",optionsClassName:"employee-options-btn-className"})),r.createElement("div",null,r.createElement(t.Card,null,r.createElement(t.StatusTable,{style:{padding:"10px 0px"}},r.createElement(t.Row,{label:""+d("UC_CHALLAN_NO"),text:v}),r.createElement("hr",{style:{width:"35%",border:"1px solid #D6D5D4",marginTop:"1rem",marginBottom:"1rem"}}),null==_?void 0:_.map(e=>r.createElement(t.Row,{label:d(p(null==e?void 0:e.taxHeadCode,".","_")),text:"₹"+(null==e?void 0:e.amount)||0,textStyle:{whiteSpace:"pre"}})),r.createElement("hr",{style:{width:"35%",border:"1px solid #D6D5D4",marginTop:"1rem",marginBottom:"1rem"}}),r.createElement(t.Row,{label:r.createElement("b",{style:{padding:"10px 0px"}},d("UC_TOTAL_DUE_AMOUT_LABEL")),text:"₹"+b,textStyle:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}})),r.createElement("div",{style:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}},d("UC_SERVICE_DETAILS_LABEL")),r.createElement(t.StatusTable,null,r.createElement(t.Row,{label:""+d("UC_SERVICE_CATEGORY_LABEL"),text:""+d("BILLINGSERVICE_BUSINESSSERVICE_"+p(null==F||null===(l=F.businessService)||void 0===l?void 0:l.toUpperCase(),".","_")||d("CS_NA")),textStyle:{whiteSpace:"pre"}}),r.createElement(t.Row,{label:""+d("UC_FROM_DATE_LABEL"),text:m(null==F?void 0:F.taxPeriodFrom)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_TO_DATE_LABEL"),text:m(null==F?void 0:F.taxPeriodTo)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_COMMENT_LABEL"),text:""+((null==F?void 0:F.description)||d("CS_NA"))}),r.createElement(t.Row,{label:""+d("CS_INBOX_STATUS_FILTER"),text:d("UC_"+((null==F?void 0:F.applicationStatus)||d("CS_NA")))})),r.createElement("div",{style:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}},d("UC_CONSUMER_DETAILS_LABEL")),r.createElement(t.StatusTable,null,r.createElement(t.Row,{label:""+d("UC_CONS_NAME_LABEL"),text:(null==F?void 0:F.citizen.name)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_MOBILE_NUMBER"),text:(null==F?void 0:F.citizen.mobileNumber)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_EMAIL_ID"),text:(null==F?void 0:F.citizen.emailId)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_DOOR_NO_LABEL"),text:(null==F?void 0:F.address.doorNo)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_BUILDING_NAME_LABEL"),text:(null==F?void 0:F.address.buildingName)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_STREET_NAME_LABEL"),text:(null==F?void 0:F.address.street)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_MOHALLA_LABEL"),text:""+d(`${p(null==F||null===(u=F.address)||void 0===u||null===(c=u.tenantId)||void 0===c?void 0:c.toUpperCase(),".","_")}_REVENUE_${null==F||null===(s=F.address)||void 0===s||null===(f=s.locality)||void 0===f?void 0:f.code}`||d("CS_NA"))})))),A?r.createElement(L,{t:d,action:x,applicationData:F,billData:_,closeModal:B,submitAction:e=>{Digit.MCollectService.update({Challan:null==e?void 0:e.Challan},h).then(e=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];Digit.SessionStorage.set("isMcollectAppChanged",t.challanNo),T.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${null==t?void 0:t.tenantId}&serviceCategory=${t.businessService}&challanNumber=${t.challanNo}&applicationStatus=${t.applicationStatus}`,{from:D})}}).catch(e=>{var t,n;return k({key:!0,label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})}),B()}}):null,P&&r.createElement(t.Toast,{error:P.key,label:d(P.label),onClose:()=>k(null)}),"ACTIVE"==(null==F?void 0:F.applicationStatus)&&r.createElement(t.ActionBar,null,S&&V?r.createElement(t.Menu,{localeKeyPrefix:"UC",options:V,t:d,onSelect:function(e){I(e),N(!1)}}):null,r.createElement(t.SubmitBar,{label:d("ES_COMMON_TAKE_ACTION"),onSubmit:()=>N(!S)})))},MCollectAcknowledgement:()=>{const e=i.useLocation(),[a,l]=n.useState({}),{isEdit:u}=Digit.Hooks.useQueryParams();n.useEffect(()=>{var t;l((t=e.search)?(/^[?#]/.test(t)?t.slice(1):t).split("&").reduce((e,t)=>{let[n,r]=t.split("=");return e[n]=r?decodeURIComponent(r.replace(/\+/g," ")):"",e},{}):{})},[e]);const{t:c}=o.useTranslation(),s=function(){try{return g(null==a?void 0:a.challanNumber,"print"),Promise.resolve()}catch(e){return Promise.reject(e)}};return r.createElement("div",null,"CANCELLED"===(null==a?void 0:a.applicationStatus)?r.createElement(t.Card,null,r.createElement(t.Banner,{message:c("UC_BILL_CANCELLED_SUCCESS_MESSAGE"),applicationNumber:null==a?void 0:a.challanNumber,info:c("UC_CHALLAN_NO"),successful:!0}),r.createElement(t.CardText,null,c("UC_BILL_CANCELLED_SUCCESS_SUB_MESSAGE")),r.createElement("div",{className:"primary-label-btn d-grid",style:{marginLeft:"unset"},onClick:s},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24",viewBox:"0 0 24 24",width:"24"},r.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),r.createElement("path",{d:"M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"})),c("UC_PRINT_CHALLAN_LABEL")),r.createElement(t.ActionBar,{style:{display:"flex",justifyContent:"flex-end",alignItems:"baseline"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{marginRight:"1rem"}},r.createElement(t.SubmitBar,{label:c("CORE_COMMON_GO_TO_HOME")})))):r.createElement(t.Card,null,r.createElement(t.Banner,{message:c(u?"UC_BILL_UPDATED_SUCCESS_MESSAGE":"UC_BILL_GENERATED_SUCCESS_MESSAGE"),applicationNumber:null==a?void 0:a.challanNumber,info:c("UC_CHALLAN_NO"),successful:!0}),r.createElement(t.CardText,null,c("UC_BILL_GENERATION_MESSAGE_SUB")),r.createElement("div",{className:"primary-label-btn d-grid",style:{marginLeft:"unset"},onClick:s},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24",viewBox:"0 0 24 24",width:"24"},r.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),r.createElement("path",{d:"M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"})),c("UC_PRINT_CHALLAN_LABEL")),r.createElement(t.ActionBar,{style:{display:"flex",justifyContent:"flex-end",alignItems:"baseline"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{marginRight:"1rem"}},r.createElement(t.LinkButton,{style:{color:"#FF8C00"},label:c("CORE_COMMON_GO_TO_HOME")})),r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null==a?void 0:a.serviceCategory}/${null==a?void 0:a.challanNumber}/tenantId=${null==a?void 0:a.tenantId}?workflow=mcollect`}},r.createElement(t.SubmitBar,{label:c("UC_BUTTON_PAY")})))))},MCollectEditChallan:()=>{const e=Digit.ULBService.getCurrentTenantId();o.useTranslation();let{challanNo:t}=i.useParams(),n=Digit.SessionStorage.get("isMcollectAppChanged");sessionStorage.setItem("isHookRecall",!0);const{isLoading:a,data:l}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:e,filters:{challanNo:t},isMcollectAppChanged:n});return l&&!a?r.createElement(on,{ChallanData:null==l?void 0:l.challans,tenantId:e}):null},MCollectNewChallan:on,MCollectSearchChallanComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>Ht.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[Ht]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement($t,{config:a[0]})))},MCollectSearchResultsComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>zt.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[zt]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement(Vt,{template:a[0].labels,header:a[0].texts.header,actionButtonLabel:a[0].texts.actionButtonLabel,t:e})))},MCollectMyChallanResultsComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>pe.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[pe]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement(Ft,{template:a[0].labels,header:a[0].texts.header,actionButtonLabel:a[0].texts.actionButtonLabel,t:e})))},MCOLLECT_INBOX_FILTER:e=>r.createElement(_,e)};exports.MCollectLinks=ln,exports.MCollectModule=an,exports.initMCollectComponents=()=>{Object.entries(un).forEach(e=>{let[t,n]=e;Digit.ComponentRegistryService.setComponent(t,n)})};
|
|
10
|
+
var me="function"==typeof Symbol&&Symbol.for,ve=me?Symbol.for("react.element"):60103,he=me?Symbol.for("react.portal"):60106,ge=me?Symbol.for("react.fragment"):60107,ye=me?Symbol.for("react.strict_mode"):60108,_e=me?Symbol.for("react.profiler"):60114,Ee=me?Symbol.for("react.provider"):60109,be=me?Symbol.for("react.context"):60110,Ce=me?Symbol.for("react.async_mode"):60111,Se=me?Symbol.for("react.concurrent_mode"):60111,Le=me?Symbol.for("react.forward_ref"):60112,Ne=me?Symbol.for("react.suspense"):60113,Ae=me?Symbol.for("react.suspense_list"):60120,we=me?Symbol.for("react.memo"):60115,xe=me?Symbol.for("react.lazy"):60116,Ie=me?Symbol.for("react.block"):60121,Te=me?Symbol.for("react.fundamental"):60117,De=me?Symbol.for("react.responder"):60118,Oe=me?Symbol.for("react.scope"):60119;function Re(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case ve:switch(e=e.type){case Ce:case Se:case ge:case _e:case ye:case Ne:return e;default:switch(e=e&&e.$$typeof){case be:case Le:case xe:case we:case Ee:return e;default:return t}}case he:return t}}}function Pe(e){return Re(e)===Se}var ke={AsyncMode:Ce,ConcurrentMode:Se,ContextConsumer:be,ContextProvider:Ee,Element:ve,ForwardRef:Le,Fragment:ge,Lazy:xe,Memo:we,Portal:he,Profiler:_e,StrictMode:ye,Suspense:Ne,isAsyncMode:function(e){return Pe(e)||Re(e)===Ce},isConcurrentMode:Pe,isContextConsumer:function(e){return Re(e)===be},isContextProvider:function(e){return Re(e)===Ee},isElement:function(e){return"object"==typeof e&&null!==e&&e.$$typeof===ve},isForwardRef:function(e){return Re(e)===Le},isFragment:function(e){return Re(e)===ge},isLazy:function(e){return Re(e)===xe},isMemo:function(e){return Re(e)===we},isPortal:function(e){return Re(e)===he},isProfiler:function(e){return Re(e)===_e},isStrictMode:function(e){return Re(e)===ye},isSuspense:function(e){return Re(e)===Ne},isValidElementType:function(e){return"string"==typeof e||"function"==typeof e||e===ge||e===Se||e===_e||e===ye||e===Ne||e===Ae||"object"==typeof e&&null!==e&&(e.$$typeof===xe||e.$$typeof===we||e.$$typeof===Ee||e.$$typeof===be||e.$$typeof===Le||e.$$typeof===Te||e.$$typeof===De||e.$$typeof===Oe||e.$$typeof===Ie)},typeOf:Re},Be=f(function(e,t){"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,n=e?Symbol.for("react.element"):60103,r=e?Symbol.for("react.portal"):60106,o=e?Symbol.for("react.fragment"):60107,i=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,l=e?Symbol.for("react.provider"):60109,u=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,s=e?Symbol.for("react.concurrent_mode"):60111,f=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,p=e?Symbol.for("react.suspense_list"):60120,m=e?Symbol.for("react.memo"):60115,v=e?Symbol.for("react.lazy"):60116,h=e?Symbol.for("react.block"):60121,g=e?Symbol.for("react.fundamental"):60117,y=e?Symbol.for("react.responder"):60118,_=e?Symbol.for("react.scope"):60119;function E(e){if("object"==typeof e&&null!==e){var t=e.$$typeof;switch(t){case n:var p=e.type;switch(p){case c:case s:case o:case a:case i:case d:return p;default:var h=p&&p.$$typeof;switch(h){case u:case f:case v:case m:case l:return h;default:return t}}case r:return t}}}var b=s,C=u,S=l,L=n,N=f,A=o,w=v,x=m,I=r,T=a,D=i,O=d,R=!1;function P(e){return E(e)===s}t.AsyncMode=c,t.ConcurrentMode=b,t.ContextConsumer=C,t.ContextProvider=S,t.Element=L,t.ForwardRef=N,t.Fragment=A,t.Lazy=w,t.Memo=x,t.Portal=I,t.Profiler=T,t.StrictMode=D,t.Suspense=O,t.isAsyncMode=function(e){return R||(R=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),P(e)||E(e)===c},t.isConcurrentMode=P,t.isContextConsumer=function(e){return E(e)===u},t.isContextProvider=function(e){return E(e)===l},t.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===n},t.isForwardRef=function(e){return E(e)===f},t.isFragment=function(e){return E(e)===o},t.isLazy=function(e){return E(e)===v},t.isMemo=function(e){return E(e)===m},t.isPortal=function(e){return E(e)===r},t.isProfiler=function(e){return E(e)===a},t.isStrictMode=function(e){return E(e)===i},t.isSuspense=function(e){return E(e)===d},t.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===o||e===s||e===a||e===i||e===d||e===p||"object"==typeof e&&null!==e&&(e.$$typeof===v||e.$$typeof===m||e.$$typeof===l||e.$$typeof===u||e.$$typeof===f||e.$$typeof===g||e.$$typeof===y||e.$$typeof===_||e.$$typeof===h)},t.typeOf=E}()}),Ue=f(function(e){e.exports="production"===process.env.NODE_ENV?ke:Be}),Me=Object.getOwnPropertySymbols,je=Object.prototype.hasOwnProperty,Fe=Object.prototype.propertyIsEnumerable;function He(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}var $e=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map(function(e){return t[e]}).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach(function(e){r[e]=e}),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(e,t){for(var n,r,o=He(e),i=1;i<arguments.length;i++){for(var a in n=Object(arguments[i]))je.call(n,a)&&(o[a]=n[a]);if(Me){r=Me(n);for(var l=0;l<r.length;l++)Fe.call(n,r[l])&&(o[r[l]]=n[r[l]])}}return o},ze="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED",Ve=Function.call.bind(Object.prototype.hasOwnProperty),We=function(){};if("production"!==process.env.NODE_ENV){var qe=ze,Ge={},Ke=Ve;We=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function Ye(e,t,n,r,o){if("production"!==process.env.NODE_ENV)for(var i in e)if(Ke(e,i)){var a;try{if("function"!=typeof e[i]){var l=Error((r||"React class")+": "+n+" type `"+i+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof e[i]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw l.name="Invariant Violation",l}a=e[i](t,i,r,n,null,qe)}catch(e){a=e}if(!a||a instanceof Error||We((r||"React class")+": type specification of "+n+" `"+i+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof a+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),a instanceof Error&&!(a.message in Ge)){Ge[a.message]=!0;var u=o?o():"";We("Failed "+n+" type: "+a.message+(null!=u?u:""))}}}Ye.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(Ge={})};var Je=Ye,Ze=function(){};function Qe(){return null}function Xe(){}function et(){}"production"!==process.env.NODE_ENV&&(Ze=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),et.resetWarningCache=Xe;var tt=f(function(e){e.exports="production"!==process.env.NODE_ENV?function(e,t){var n="function"==typeof Symbol&&Symbol.iterator,r={array:l("array"),bigint:l("bigint"),bool:l("boolean"),func:l("function"),number:l("number"),object:l("object"),string:l("string"),symbol:l("symbol"),any:a(Qe),arrayOf:function(e){return a(function(t,n,r,o,a){if("function"!=typeof e)return new i("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside arrayOf.");var l=t[n];if(!Array.isArray(l))return new i("Invalid "+o+" `"+a+"` of type `"+s(l)+"` supplied to `"+r+"`, expected an array.");for(var u=0;u<l.length;u++){var c=e(l,u,r,o,a+"["+u+"]",ze);if(c instanceof Error)return c}return null})},element:a(function(t,n,r,o,a){var l=t[n];return e(l)?null:new i("Invalid "+o+" `"+a+"` of type `"+s(l)+"` supplied to `"+r+"`, expected a single ReactElement.")}),elementType:a(function(e,t,n,r,o){var a=e[t];return Ue.isValidElementType(a)?null:new i("Invalid "+r+" `"+o+"` of type `"+s(a)+"` supplied to `"+n+"`, expected a single ReactElement type.")}),instanceOf:function(e){return a(function(t,n,r,o,a){var l;return t[n]instanceof e?null:new i("Invalid "+o+" `"+a+"` of type `"+((l=t[n]).constructor&&l.constructor.name?l.constructor.name:"<<anonymous>>")+"` supplied to `"+r+"`, expected instance of `"+(e.name||"<<anonymous>>")+"`.")})},node:a(function(e,t,n,r,o){return c(e[t])?null:new i("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")}),objectOf:function(e){return a(function(t,n,r,o,a){if("function"!=typeof e)return new i("Property `"+a+"` of component `"+r+"` has invalid PropType notation inside objectOf.");var l=t[n],u=s(l);if("object"!==u)return new i("Invalid "+o+" `"+a+"` of type `"+u+"` supplied to `"+r+"`, expected an object.");for(var c in l)if(Ve(l,c)){var f=e(l,c,r,o,a+"."+c,ze);if(f instanceof Error)return f}return null})},oneOf:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&Ze(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),Qe;function t(t,n,r,a,l){for(var u=t[n],c=0;c<e.length;c++)if(o(u,e[c]))return null;var s=JSON.stringify(e,function(e,t){return"symbol"===f(t)?String(t):t});return new i("Invalid "+a+" `"+l+"` of value `"+String(u)+"` supplied to `"+r+"`, expected one of "+s+".")}return a(t)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&Ze("Invalid argument supplied to oneOfType, expected an instance of array."),Qe;for(var t=0;t<e.length;t++){var n=e[t];if("function"!=typeof n)return Ze("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+d(n)+" at index "+t+"."),Qe}return a(function(t,n,r,o,a){for(var l=[],u=0;u<e.length;u++){var c=(0,e[u])(t,n,r,o,a,ze);if(null==c)return null;c.data&&Ve(c.data,"expectedType")&&l.push(c.data.expectedType)}return new i("Invalid "+o+" `"+a+"` supplied to `"+r+"`"+(l.length>0?", expected one of type ["+l.join(", ")+"]":"")+".")})},shape:function(e){return a(function(t,n,r,o,a){var l=t[n],c=s(l);if("object"!==c)return new i("Invalid "+o+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected `object`.");for(var d in e){var p=e[d];if("function"!=typeof p)return u(r,o,a,d,f(p));var m=p(l,d,r,o,a+"."+d,ze);if(m)return m}return null})},exact:function(e){return a(function(t,n,r,o,a){var l=t[n],c=s(l);if("object"!==c)return new i("Invalid "+o+" `"+a+"` of type `"+c+"` supplied to `"+r+"`, expected `object`.");var d=$e({},t[n],e);for(var p in d){var m=e[p];if(Ve(e,p)&&"function"!=typeof m)return u(r,o,a,p,f(m));if(!m)return new i("Invalid "+o+" `"+a+"` key `"+p+"` supplied to `"+r+"`.\nBad object: "+JSON.stringify(t[n],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var v=m(l,p,r,o,a+"."+p,ze);if(v)return v}return null})}};function o(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function i(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function a(e){function t(t,n,r,o,a,l,u){if(o=o||"<<anonymous>>",l=l||r,u!==ze){var c=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw c.name="Invariant Violation",c}return null==n[r]?t?new i(null===n[r]?"The "+a+" `"+l+"` is marked as required in `"+o+"`, but its value is `null`.":"The "+a+" `"+l+"` is marked as required in `"+o+"`, but its value is `undefined`."):null:e(n,r,o,a,l)}process;var n=t.bind(null,!1);return n.isRequired=t.bind(null,!0),n}function l(e){return a(function(t,n,r,o,a,l){var u=t[n];return s(u)!==e?new i("Invalid "+o+" `"+a+"` of type `"+f(u)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null})}function u(e,t,n,r,o){return new i((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function c(t){switch(typeof t){case"number":case"string":case"undefined":return!0;case"boolean":return!t;case"object":if(Array.isArray(t))return t.every(c);if(null===t||e(t))return!0;var r=function(e){var t=e&&(n&&e[n]||e["@@iterator"]);if("function"==typeof t)return t}(t);if(!r)return!1;var o,i=r.call(t);if(r!==t.entries){for(;!(o=i.next()).done;)if(!c(o.value))return!1}else for(;!(o=i.next()).done;){var a=o.value;if(a&&!c(a[1]))return!1}return!0;default:return!1}}function s(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function f(e){if(null==e)return""+e;var t=s(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function d(e){var t=f(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return i.prototype=Error.prototype,r.checkPropTypes=Je,r.resetWarningCache=Je.resetWarningCache,r.PropTypes=r,r}(Ue.isElement):function(){function e(e,t,n,r,o,i){if(i!==ze){var a=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw a.name="Invariant Violation",a}}function t(){return e}e.isRequired=e;var n={array:e,bigint:e,bool:e,func:e,number:e,object:e,string:e,symbol:e,any:e,arrayOf:t,element:e,elementType:e,instanceOf:t,node:e,objectOf:t,oneOf:t,oneOfType:t,shape:t,exact:t,checkPropTypes:et,resetWarningCache:Xe};return n.PropTypes=n,n}()}),nt=function(e,t){return function(){for(var n=new Array(arguments.length),r=0;r<n.length;r++)n[r]=arguments[r];return e.apply(t,n)}},rt=Object.prototype.toString;function ot(e){return"[object Array]"===rt.call(e)}function it(e){return void 0===e}function at(e){return null!==e&&"object"==typeof e}function lt(e){if("[object Object]"!==rt.call(e))return!1;var t=Object.getPrototypeOf(e);return null===t||t===Object.prototype}function ut(e){return"[object Function]"===rt.call(e)}function ct(e,t){if(null!=e)if("object"!=typeof e&&(e=[e]),ot(e))for(var n=0,r=e.length;n<r;n++)t.call(null,e[n],n,e);else for(var o in e)Object.prototype.hasOwnProperty.call(e,o)&&t.call(null,e[o],o,e)}var st={isArray:ot,isArrayBuffer:function(e){return"[object ArrayBuffer]"===rt.call(e)},isBuffer:function(e){return null!==e&&!it(e)&&null!==e.constructor&&!it(e.constructor)&&"function"==typeof e.constructor.isBuffer&&e.constructor.isBuffer(e)},isFormData:function(e){return"undefined"!=typeof FormData&&e instanceof FormData},isArrayBufferView:function(e){return"undefined"!=typeof ArrayBuffer&&ArrayBuffer.isView?ArrayBuffer.isView(e):e&&e.buffer&&e.buffer instanceof ArrayBuffer},isString:function(e){return"string"==typeof e},isNumber:function(e){return"number"==typeof e},isObject:at,isPlainObject:lt,isUndefined:it,isDate:function(e){return"[object Date]"===rt.call(e)},isFile:function(e){return"[object File]"===rt.call(e)},isBlob:function(e){return"[object Blob]"===rt.call(e)},isFunction:ut,isStream:function(e){return at(e)&&ut(e.pipe)},isURLSearchParams:function(e){return"undefined"!=typeof URLSearchParams&&e instanceof URLSearchParams},isStandardBrowserEnv:function(){return("undefined"==typeof navigator||"ReactNative"!==navigator.product&&"NativeScript"!==navigator.product&&"NS"!==navigator.product)&&"undefined"!=typeof window&&"undefined"!=typeof document},forEach:ct,merge:function e(){var t={};function n(n,r){t[r]=lt(t[r])&<(n)?e(t[r],n):lt(n)?e({},n):ot(n)?n.slice():n}for(var r=0,o=arguments.length;r<o;r++)ct(arguments[r],n);return t},extend:function(e,t,n){return ct(t,function(t,r){e[r]=n&&"function"==typeof t?nt(t,n):t}),e},trim:function(e){return e.replace(/^\s*/,"").replace(/\s*$/,"")},stripBOM:function(e){return 65279===e.charCodeAt(0)&&(e=e.slice(1)),e}};function ft(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}var dt=function(e,t,n){if(!t)return e;var r;if(n)r=n(t);else if(st.isURLSearchParams(t))r=t.toString();else{var o=[];st.forEach(t,function(e,t){null!=e&&(st.isArray(e)?t+="[]":e=[e],st.forEach(e,function(e){st.isDate(e)?e=e.toISOString():st.isObject(e)&&(e=JSON.stringify(e)),o.push(ft(t)+"="+ft(e))}))}),r=o.join("&")}if(r){var i=e.indexOf("#");-1!==i&&(e=e.slice(0,i)),e+=(-1===e.indexOf("?")?"?":"&")+r}return e};function pt(){this.handlers=[]}pt.prototype.use=function(e,t){return this.handlers.push({fulfilled:e,rejected:t}),this.handlers.length-1},pt.prototype.eject=function(e){this.handlers[e]&&(this.handlers[e]=null)},pt.prototype.forEach=function(e){st.forEach(this.handlers,function(t){null!==t&&e(t)})};var mt=pt,vt=function(e,t,n){return st.forEach(n,function(n){e=n(e,t)}),e},ht=function(e){return!(!e||!e.__CANCEL__)},gt=function(e,t){st.forEach(e,function(n,r){r!==t&&r.toUpperCase()===t.toUpperCase()&&(e[t]=n,delete e[r])})},yt=function(e,t,n,r,o){return function(e,t,n,r,o){return e.config=t,n&&(e.code=n),e.request=r,e.response=o,e.isAxiosError=!0,e.toJSON=function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:this.config,code:this.code}},e}(new Error(e),t,n,r,o)},_t=st.isStandardBrowserEnv()?{write:function(e,t,n,r,o,i){var a=[];a.push(e+"="+encodeURIComponent(t)),st.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),st.isString(r)&&a.push("path="+r),st.isString(o)&&a.push("domain="+o),!0===i&&a.push("secure"),document.cookie=a.join("; ")},read:function(e){var t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove:function(e){this.write(e,"",Date.now()-864e5)}}:{write:function(){},read:function(){return null},remove:function(){}},Et=["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"],bt=st.isStandardBrowserEnv()?function(){var e,t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");function r(e){var r=e;return t&&(n.setAttribute("href",r),r=n.href),n.setAttribute("href",r),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:"/"===n.pathname.charAt(0)?n.pathname:"/"+n.pathname}}return e=r(window.location.href),function(t){var n=st.isString(t)?r(t):t;return n.protocol===e.protocol&&n.host===e.host}}():function(){return!0},Ct={"Content-Type":"application/x-www-form-urlencoded"};function St(e,t){!st.isUndefined(e)&&st.isUndefined(e["Content-Type"])&&(e["Content-Type"]=t)}var Lt,Nt={adapter:(("undefined"!=typeof XMLHttpRequest||"undefined"!=typeof process&&"[object process]"===Object.prototype.toString.call(process))&&(Lt=function(e){return new Promise(function(t,n){var r=e.data,o=e.headers;st.isFormData(r)&&delete o["Content-Type"];var i=new XMLHttpRequest;if(e.auth){var a=e.auth.username||"",l=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";o.Authorization="Basic "+btoa(a+":"+l)}var u,c,s=(c=e.url,(u=e.baseURL)&&!/^([a-z][a-z\d\+\-\.]*:)?\/\//i.test(c)?function(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}(u,c):c);if(i.open(e.method.toUpperCase(),dt(s,e.params,e.paramsSerializer),!0),i.timeout=e.timeout,i.onreadystatechange=function(){if(i&&4===i.readyState&&(0!==i.status||i.responseURL&&0===i.responseURL.indexOf("file:"))){var r,o,a,l,u,c="getAllResponseHeaders"in i?(r=i.getAllResponseHeaders(),u={},r?(st.forEach(r.split("\n"),function(e){if(l=e.indexOf(":"),o=st.trim(e.substr(0,l)).toLowerCase(),a=st.trim(e.substr(l+1)),o){if(u[o]&&Et.indexOf(o)>=0)return;u[o]="set-cookie"===o?(u[o]?u[o]:[]).concat([a]):u[o]?u[o]+", "+a:a}}),u):u):null;!function(e,t,n){var r=n.config.validateStatus;n.status&&r&&!r(n.status)?t(yt("Request failed with status code "+n.status,n.config,null,n.request,n)):e(n)}(t,n,{data:e.responseType&&"text"!==e.responseType?i.response:i.responseText,status:i.status,statusText:i.statusText,headers:c,config:e,request:i}),i=null}},i.onabort=function(){i&&(n(yt("Request aborted",e,"ECONNABORTED",i)),i=null)},i.onerror=function(){n(yt("Network Error",e,null,i)),i=null},i.ontimeout=function(){var t="timeout of "+e.timeout+"ms exceeded";e.timeoutErrorMessage&&(t=e.timeoutErrorMessage),n(yt(t,e,"ECONNABORTED",i)),i=null},st.isStandardBrowserEnv()){var f=(e.withCredentials||bt(s))&&e.xsrfCookieName?_t.read(e.xsrfCookieName):void 0;f&&(o[e.xsrfHeaderName]=f)}if("setRequestHeader"in i&&st.forEach(o,function(e,t){void 0===r&&"content-type"===t.toLowerCase()?delete o[t]:i.setRequestHeader(t,e)}),st.isUndefined(e.withCredentials)||(i.withCredentials=!!e.withCredentials),e.responseType)try{i.responseType=e.responseType}catch(t){if("json"!==e.responseType)throw t}"function"==typeof e.onDownloadProgress&&i.addEventListener("progress",e.onDownloadProgress),"function"==typeof e.onUploadProgress&&i.upload&&i.upload.addEventListener("progress",e.onUploadProgress),e.cancelToken&&e.cancelToken.promise.then(function(e){i&&(i.abort(),n(e),i=null)}),r||(r=null),i.send(r)})}),Lt),transformRequest:[function(e,t){return gt(t,"Accept"),gt(t,"Content-Type"),st.isFormData(e)||st.isArrayBuffer(e)||st.isBuffer(e)||st.isStream(e)||st.isFile(e)||st.isBlob(e)?e:st.isArrayBufferView(e)?e.buffer:st.isURLSearchParams(e)?(St(t,"application/x-www-form-urlencoded;charset=utf-8"),e.toString()):st.isObject(e)?(St(t,"application/json;charset=utf-8"),JSON.stringify(e)):e}],transformResponse:[function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(e){}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};st.forEach(["delete","get","head"],function(e){Nt.headers[e]={}}),st.forEach(["post","put","patch"],function(e){Nt.headers[e]=st.merge(Ct)});var At=Nt;function wt(e){e.cancelToken&&e.cancelToken.throwIfRequested()}var xt=function(e){return wt(e),e.headers=e.headers||{},e.data=vt(e.data,e.headers,e.transformRequest),e.headers=st.merge(e.headers.common||{},e.headers[e.method]||{},e.headers),st.forEach(["delete","get","head","post","put","patch","common"],function(t){delete e.headers[t]}),(e.adapter||At.adapter)(e).then(function(t){return wt(e),t.data=vt(t.data,t.headers,e.transformResponse),t},function(t){return ht(t)||(wt(e),t&&t.response&&(t.response.data=vt(t.response.data,t.response.headers,e.transformResponse))),Promise.reject(t)})},It=function(e,t){t=t||{};var n={},r=["url","method","data"],o=["headers","auth","proxy","params"],i=["baseURL","transformRequest","transformResponse","paramsSerializer","timeout","timeoutMessage","withCredentials","adapter","responseType","xsrfCookieName","xsrfHeaderName","onUploadProgress","onDownloadProgress","decompress","maxContentLength","maxBodyLength","maxRedirects","transport","httpAgent","httpsAgent","cancelToken","socketPath","responseEncoding"],a=["validateStatus"];function l(e,t){return st.isPlainObject(e)&&st.isPlainObject(t)?st.merge(e,t):st.isPlainObject(t)?st.merge({},t):st.isArray(t)?t.slice():t}function u(r){st.isUndefined(t[r])?st.isUndefined(e[r])||(n[r]=l(void 0,e[r])):n[r]=l(e[r],t[r])}st.forEach(r,function(e){st.isUndefined(t[e])||(n[e]=l(void 0,t[e]))}),st.forEach(o,u),st.forEach(i,function(r){st.isUndefined(t[r])?st.isUndefined(e[r])||(n[r]=l(void 0,e[r])):n[r]=l(void 0,t[r])}),st.forEach(a,function(r){r in t?n[r]=l(e[r],t[r]):r in e&&(n[r]=l(void 0,e[r]))});var c=r.concat(o).concat(i).concat(a),s=Object.keys(e).concat(Object.keys(t)).filter(function(e){return-1===c.indexOf(e)});return st.forEach(s,u),n};function Tt(e){this.defaults=e,this.interceptors={request:new mt,response:new mt}}Tt.prototype.request=function(e){"string"==typeof e?(e=arguments[1]||{}).url=arguments[0]:e=e||{},(e=It(this.defaults,e)).method=e.method?e.method.toLowerCase():this.defaults.method?this.defaults.method.toLowerCase():"get";var t=[xt,void 0],n=Promise.resolve(e);for(this.interceptors.request.forEach(function(e){t.unshift(e.fulfilled,e.rejected)}),this.interceptors.response.forEach(function(e){t.push(e.fulfilled,e.rejected)});t.length;)n=n.then(t.shift(),t.shift());return n},Tt.prototype.getUri=function(e){return e=It(this.defaults,e),dt(e.url,e.params,e.paramsSerializer).replace(/^\?/,"")},st.forEach(["delete","get","head","options"],function(e){Tt.prototype[e]=function(t,n){return this.request(It(n||{},{method:e,url:t,data:(n||{}).data}))}}),st.forEach(["post","put","patch"],function(e){Tt.prototype[e]=function(t,n,r){return this.request(It(r||{},{method:e,url:t,data:n}))}});var Dt=Tt;function Ot(e){this.message=e}Ot.prototype.toString=function(){return"Cancel"+(this.message?": "+this.message:"")},Ot.prototype.__CANCEL__=!0;var Rt=Ot;function Pt(e){if("function"!=typeof e)throw new TypeError("executor must be a function.");var t;this.promise=new Promise(function(e){t=e});var n=this;e(function(e){n.reason||(n.reason=new Rt(e),t(n.reason))})}Pt.prototype.throwIfRequested=function(){if(this.reason)throw this.reason},Pt.source=function(){var e;return{token:new Pt(function(t){e=t}),cancel:e}};var kt=Pt;function Bt(e){var t=new Dt(e),n=nt(Dt.prototype.request,t);return st.extend(n,Dt.prototype,t),st.extend(n,t),n}var Ut=Bt(At);Ut.Axios=Dt,Ut.create=function(e){return Bt(It(Ut.defaults,e))},Ut.Cancel=Rt,Ut.CancelToken=kt,Ut.isCancel=ht,Ut.all=function(e){return Promise.all(e)},Ut.spread=function(e){return function(t){return e.apply(null,t)}},Ut.isAxiosError=function(e){return"object"==typeof e&&!0===e.isAxiosError};var Mt=Ut;Mt.default=Ut;var jt=Mt;const Ft=e=>{var n,a,l,u;let{template:c,header:s,actionButtonLabel:f}=e;const{t:d}=o.useTranslation(),p=i.useHistory(),m={},v=Digit.UserService.getUser(),h=null==v||null===(n=v.info)||void 0===n?void 0:n.tenantId;m.mobileNumber=null==v||null===(a=v.info)||void 0===a?void 0:a.mobileNumber;const g=Digit.Hooks.mcollect.useMcollectSearchBill({tenantId:h,filters:m}),y=null==g||null===(l=g.data)||void 0===l||null===(u=l.Bills)||void 0===u?void 0:u.map(e=>{return{businesService:e.businessService,total_due:"ACTIVE"===e.status?e.totalAmount:0,OwnerName:e.payerName||d("CS_NA"),BillingPeriod:(t=e.billDetails[0].fromPeriod,n=e.billDetails[0].toPeriod,t&&n?new Date(t).getDate()+" "+Digit.Utils.date.monthNames[new Date(t).getMonth()]+" "+new Date(t).getFullYear()+" - "+new Date(n).getDate()+" "+Digit.Utils.date.monthNames[new Date(n).getMonth()]+" "+new Date(n).getFullYear():"N/A"),bil_due__date:new Date(e.billDetails[0].expiryDate).getDate().toString()+"/"+(new Date(e.billDetails[0].expiryDate).getMonth()+1).toString()+"/"+new Date(e.billDetails[0].expiryDate).getFullYear().toString(),ChannelNo:(null==e?void 0:e.consumerCode)||d("CS_NA"),ServiceCategory:e.businessService?e.businessService.split(".")[e.businessService.split(".").length-1]:d("CS_NA")};var t,n});return r.createElement("div",{style:{marginTop:"16px"}},r.createElement("div",null,s&&r.createElement(t.Header,{style:{marginLeft:"8px"}},d(s)," (",null==y?void 0:y.length,")"),r.createElement("div",null,r.createElement(t.ResponseComposer,{data:y,template:c,actionButtonLabel:f,onSubmit:e=>{p.push(`/digit-ui/citizen/payment/my-bills/${null==e?void 0:e.businesService}/${null==e?void 0:e.ChannelNo}?workflow=mcollect`)}}))),r.createElement("div",{style:{marginLeft:"16px",marginTop:"16px",marginBottom:"46px"}},r.createElement("p",null,d("UC_NOT_ABLE_TO_FIND_BILL_MSG")," "),r.createElement("p",{className:"link"},r.createElement(i.Link,{to:"/digit-ui/citizen/mcollect/search"},d("UC_CLICK_HERE_TO_SEARCH_LINK")))))};Ft.propTypes={template:tt.any,header:tt.string,actionButtonLabel:tt.string},Ft.defaultProps={template:[],header:null,actionButtonLabel:null};const Ht=[{texts:{header:"UC_SEARCH_CHALLAN_LABEL",submitBarLabel:"UC_SEARCH_LABEL",cardText:"UC_HOME_SEARCH_RESULTS_DESC"},inputs:[{label:"UC_SEARCH_MOBILE_NO_LABEL",type:"mobileNumber",name:"mobileNumber",error:"CORE_COMMON_PHONENO_INVALIDMSG"},{label:"UC_CHALLAN_NO",type:"number",name:"ChallanNo",error:"UC_WRONG_CHALLAN_NO"},{label:"UC_SERVICE_CATEGORY_LABEL",type:"any",name:"ServiceCategory",error:"UC_INVALID_SERVICE_CATEGORY"}]}];jt.interceptors.response.use(e=>e,e=>{var t,n;const r=window.location.pathname.split("/").includes("employee");if(null!=e&&null!==(t=e.response)&&void 0!==t&&null!==(n=t.data)&&void 0!==n&&n.Errors)for(const t of e.response.data.Errors){var o,i,a,l;t.message.includes("InvalidAccessTokenException")?(localStorage.clear(),sessionStorage.clear(),window.location.href=(r?"/digit-ui/employee/user/login":"/digit-ui/citizen/login")+"?from="+encodeURIComponent(window.location.pathname+window.location.search)):null!=t&&null!==(o=t.message)&&void 0!==o&&null!==(i=o.toLowerCase())&&void 0!==i&&i.includes("internal server error")||null!=t&&null!==(a=t.message)&&void 0!==a&&null!==(l=a.toLowerCase())&&void 0!==l&&l.includes("some error occured")?window.location.href=(r?"/digit-ui/employee/user/error":"/digit-ui/citizen/error")+"?type=maintenance&from="+encodeURIComponent(window.location.pathname+window.location.search):t.message.includes("ZuulRuntimeException")&&(window.location.href=(r?"/digit-ui/employee/user/error":"/digit-ui/citizen/error")+"?type=notfound&from="+encodeURIComponent(window.location.pathname+window.location.search))}throw e}),window.Digit=window.Digit||{},window.Digit={...window.Digit,RequestCache:window.Digit.RequestCache||{}};const $t=e=>{var a;let{config:l,formData:u}=e;const{t:c}=o.useTranslation();let s={};const f=i.useHistory(),d=Digit.ULBService.getCurrentTenantId(),[p,m]=n.useState((null==u?void 0:u.mobileNumber)||""),[v,h]=n.useState((null==u?void 0:u.challanNo)||""),[g,y]=n.useState((null==u?void 0:u.Servicecateogry)||""),[_,E]=n.useState((null==u?void 0:u.city)||""),b=null===(a=Digit.Hooks.mcollect.usemcollectTenants())||void 0===a?void 0:a.sort((e,t)=>{var n,r;return null==e||null===(n=e.i18nKey)||void 0===n||null===(r=n.localeCompare)||void 0===r?void 0:r.call(n,null==t?void 0:t.i18nKey)}),[C,S]=n.useState(null),{data:L,isLoading:A}=Digit.Hooks.mcollect.useMCollectMDMS(d,"BillingService","BusinessService");if(A)return r.createElement(t.Loader,null);let w=[];return L&&L.map(e=>{e.billGineiURL&&w.push({i18nKey:""+e.i18nKey.toUpperCase().replaceAll(".","_"),code:e.i18nKey})}),r.createElement("div",{style:{marginTop:"16px"}},r.createElement(t.FormStep,{config:l,label:l.texts.submitButtonLabel,heading:l.texts.header,text:l.texts.text,cardStyle:{margin:"auto",maxWidth:"960px"},headingStyle:{fontSize:"32px",marginBottom:"16px"},onSelect:function(e){try{return p||v||g||_?g?_.code?(f.push(`/digit-ui/citizen/mcollect/search-results?mobileNumber=${p}&challanNo=${v}&Servicecategory=${g?g.code.replace("BILLINGSERVICE_BUSINESSSERVICE_",""):""}&tenantId=${_.code}`),Promise.resolve()):Promise.resolve(alert("Please Provide City")):Promise.resolve(alert("Please Provide Service Category")):Promise.resolve(alert("Provide at least one parameter"))}catch(e){return Promise.reject(e)}},componentInFront:r.createElement("div",{className:"employee-card-input employee-card-input--front"},"+91"),isDisabled:!g||!_.code,forcedError:c(C),t:c},r.createElement(t.CardLabel,null,c("UC_CITY_LABEL")+"*"),r.createElement(t.RadioOrSelect,N({className:"form-field",isMandatory:!0,t:c,optionKey:"code",name:"City",options:b,value:_,selectedOption:_,onSelect:function(e){E(e)}},s={isRequired:!0,title:c("UC_CITY_MANDATORY")})),r.createElement(t.CardLabel,null,c("UC_SERVICE_CATEGORY_LABEL")+"*"),L&&r.createElement(t.RadioOrSelect,N({t:c,optionKey:"i18nKey",name:"Servicecategory",options:w,value:g,selectedOption:g,onSelect:function(e){y(e)}},s={isRequired:!0,title:c("please enter service category")})),r.createElement(t.CardLabel,null,""+c("UC_SEARCH_MOBILE_NO_LABEL")),r.createElement("div",{className:"field-container"},r.createElement("span",{className:"employee-card-input employee-card-input--front",style:{marginTop:"-1px"}},"+91"),r.createElement(t.TextInput,N({type:"mobileNumber",t:c,isMandatory:!1,style:{maxWidth:"500px"},optionKey:"i18nKey",name:"mobileNumber",value:p,onChange:function(e){S(null),e.target.value.match("^\\d{10}$")||S("CORE_COMMON_PHONENO_INVALIDMSG"),m(e.target.value)}},s={isRequired:!1,pattern:"[6-9]{1}[0-9]{9}",type:"tel",title:c("CORE_COMMON_APPLICANT_MOBILE_NUMBER_INVALID")}))),r.createElement(t.CardLabel,null,""+c("UC_CHALLAN_NO")),r.createElement(t.TextInput,{t:c,type:"any",isMandatory:!1,optionKey:"i18nKey",name:"ChallanNo",value:v,onChange:function(e){h(e.target.value)}})))};$t.propTypes={loginParams:tt.any},$t.defaultProps={loginParams:null};const zt=[{texts:{header:"CS_SEARCH_RESULTS",actionButtonLabel:"CS_VIEW_DETAILS"},labels:[{label:"UC_AMOUNT_DUE_LABEL",key:"total_due",noteStyle:{fontSize:"24px",fontWeight:"bold"},notePrefix:"₹ "},{label:"UC_CHALLAN_NO",key:"ChannelNo"},{label:"UC_SERVICE_CATEGORY_LABEL",key:"ServiceCategory"},{label:"UC_OWNER_NAME_LABEL",key:"OwnerName"},{label:"UC_DUE_DATE",key:"bil_due__date"}]}],Vt=e=>{var n,a;let{template:l,header:u,actionButtonLabel:c}=e;const{t:s}=o.useTranslation(),f=i.useHistory(),{mobileNumber:d,challanNo:p,Servicecategory:m,tenantId:v}=Digit.Hooks.useQueryParams(),h={};d&&(h.mobileNumber=d),p&&(h.consumerCode=p),m&&(h.businesService=m);const g=Digit.Hooks.mcollect.useMcollectSearchBill({tenantId:v,filters:h});if(g.isLoading)return r.createElement(t.Loader,null);const y=null==g||null===(n=g.data)||void 0===n||null===(a=n.Bills)||void 0===a?void 0:a.map(e=>({businesService:e.businessService,total_due:"ACTIVE"===e.status?e.totalAmount:0,OwnerName:e.payerName||s("CS_NA"),bil_due__date:new Date(e.billDetails[0].expiryDate).getDate().toString()+"/"+(new Date(e.billDetails[0].expiryDate).getMonth()+1).toString()+"/"+new Date(e.billDetails[0].expiryDate).getFullYear().toString(),ChannelNo:(null==e?void 0:e.consumerCode)||s("CS_NA"),ServiceCategory:e.businessService?e.businessService.split(".")[e.businessService.split(".").length-1]:s("CS_NA")}));return r.createElement("div",{style:{marginTop:"16px"}},r.createElement("div",null,u&&r.createElement(t.Header,{style:{marginLeft:"8px"}},s(u)," (",null==y?void 0:y.length,")"),r.createElement(t.ResponseComposer,{data:y,template:l,actionButtonLabel:c,onSubmit:e=>{f.push(`/digit-ui/citizen/payment/my-bills/${null==e?void 0:e.businesService}/${null==e?void 0:e.ChannelNo}?workflow=mcollect`)}})))};Vt.propTypes={template:tt.any,header:tt.string,actionButtonLabel:tt.string},Vt.defaultProps={template:[],header:null,actionButtonLabel:null};const Wt=function(){function e(){}return e.prototype.then=function(t,n){const r=new e,o=this.s;if(o){const e=1&o?t:n;if(e){try{qt(r,1,e(this.v))}catch(e){qt(r,2,e)}return r}return this}return this.o=function(e){try{const o=e.v;1&e.s?qt(r,1,t?t(o):o):n?qt(r,1,n(o)):qt(r,2,o)}catch(e){qt(r,2,e)}},r},e}();function qt(e,t,n){if(!e.s){if(n instanceof Wt){if(!n.s)return void(n.o=qt.bind(null,e,t));1&t&&(t=n.s),n=n.v}if(n&&n.then)return void n.then(qt.bind(null,e,t),qt.bind(null,e,2));e.s=t,e.v=n;const r=e.o;r&&r(e)}}"undefined"!=typeof Symbol&&(Symbol.iterator||(Symbol.iterator=Symbol("Symbol.iterator"))),"undefined"!=typeof Symbol&&(Symbol.asyncIterator||(Symbol.asyncIterator=Symbol("Symbol.asyncIterator")));const Gt=e=>{let{t:n,currentPage:o,columns:i,data:a,getCellProps:l,disableSort:u,onSort:c,onNextPage:s,onPrevPage:f,onFirstPage:d,onLastPage:p,onPageSizeChange:m,pageSizeLimit:v,sortParams:h,totalRecords:g,isPaginationRequired:y}=e;return r.createElement(t.Table,{t:n,data:a,currentPage:o,columns:i,getCellProps:l,onNextPage:s,onPrevPage:f,onLastPage:p,onFirstPage:d,pageSizeLimit:v,disableSort:u,onPageSizeChange:m,onSort:c,sortParams:h,totalRecords:g,isPaginationRequired:y})},Kt=e=>{const{t:a}=o.useTranslation(),[l,u]=n.useState([]),c=[{text:a("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application",roles:[]}];return n.useEffect(()=>{u(c)},[]),r.createElement(t.Card,{style:{paddingRight:0,marginTop:0},className:"employeeCard filter inboxLinks"},r.createElement("div",{className:"complaint-links-container"},r.createElement("div",{className:"header",style:{justifyContent:"flex-start"}},r.createElement("span",{className:"logo"},r.createElement(t.PTIcon,null))," ",r.createElement("span",{className:"text"},a("UC_COMMON_HEADER_SEARCH"))),r.createElement("div",{className:"body"},l.map((e,t)=>{let{link:n,text:o,hyperlink:l=!1,accessTo:u=[]}=e;return r.createElement("span",{className:"link",key:t},l?r.createElement("a",{href:n},a(o)):r.createElement(i.Link,{to:n},a(o)))}))))},Yt=e=>{var n;let{onSearch:i,type:l,onClose:u,searchFields:c,searchParams:s,isInboxPage:f}=e;const{t:d}=o.useTranslation(),{register:p,handleSubmit:m,reset:v,watch:h,control:g}=a.useForm({defaultValues:s}),y=innerWidth<=640;function _(){const e=c.reduce((e,t)=>({...e,[null==t?void 0:t.name]:""}),{});v(e);const t={...s};t.delete=[],c.forEach(e=>{t.delete.push(null==e?void 0:e.name)}),i({...t})}const E=e=>r.createElement(t.LinkLabel,{style:{display:"inline",...e?{margin:0}:{}},onClick:_},d("UC_CLEAR_SEARCH_LABEL"));return r.createElement("form",{onSubmit:m(e=>{e.mobileNumber||delete e.mobileNumber,e.delete=[],c.forEach(t=>{e[t.name]||e.delete.push(t.name)}),i(e),"mobile"===l&&u()})},r.createElement(r.Fragment,null,r.createElement("div",{className:"search-container",style:{width:"auto",marginLeft:f?"24px":"revert"}},r.createElement("div",{className:"search-complaint-container"},("mobile"===l||y)&&r.createElement("div",{className:"complaint-header"},r.createElement("h2",null,d("ES_COMMON_SEARCH_BY")),r.createElement("span",{onClick:u},r.createElement(t.CloseSvg,null))),r.createElement("div",{className:"complaint-input-container for-pt "+("desktop"!==l||y?"for-search":""),style:{width:"100%",display:"grid"}},null==c||null===(n=c.filter(e=>!0))||void 0===n?void 0:n.map((e,n)=>r.createElement("div",{key:e.name,className:"input-fields"},r.createElement("span",{key:n,className:"complaint-input"}," ",r.createElement(t.Label,null,e.label),"date"!==e.type?r.createElement("div",{className:"field-container"},null!=e&&e.componentInFront?r.createElement("span",{className:"citizen-card-input citizen-card-input--front",style:{flex:"none"}},null==e?void 0:e.componentInFront):null,r.createElement(t.TextInput,N({},e,{inputRef:p,watch:h,shouldUpdate:!0}))):r.createElement(a.Controller,{render:e=>r.createElement(t.DatePicker,{date:e.value,onChange:e.onChange}),name:e.name,control:g,defaultValue:null})," "))),"desktop"===l&&!y&&r.createElement("div",{style:{gridColumn:"2/3",textAlign:"right",paddingTop:"10px"},className:"input-fields"},r.createElement("div",null,E())),"desktop"===l&&!y&&r.createElement("div",{style:{maxWidth:"unset",marginLeft:"unset"},className:"search-submit-wrapper"},r.createElement(t.SubmitBar,{className:"submit-bar-search",label:d("UC_SEARCH_LABEL"),submit:!0}),!f&&r.createElement("div",null,E()))))),("mobile"===l||y)&&r.createElement(t.ActionBar,{className:"clear-search-container"},r.createElement("button",{className:"clear-search",style:{flex:1}},E(y)),r.createElement(t.SubmitBar,{label:d("UC_SEARCH_LABEL"),style:{flex:1},submit:!0}))))},Jt=e=>{let{filterComponent:a,...l}=e;const{data:u}=l,{t:c}=o.useTranslation(),[s,f]=n.useState(()=>{var e;return null===(e=Digit.ComponentRegistryService)||void 0===e?void 0:e.getComponent(a)}),d=e=>r.createElement("span",{className:"cell-text"},e),p=e=>{if(null==e||null==e||""==e)return"NA";const t=new Date(e);let n=t.getMonth()+1,r=t.getDate();return n=(n>9?"":"0")+n,r=(r>9?"":"0")+r,`${r}/${n}/${t.getFullYear()}`},m=e=>r.createElement("span",{className:"sla-cell"},e);let v;return l.isLoading||l.isLoader?v=r.createElement(t.Loader,null):0===(null==u?void 0:u.length)?v=r.createElement(t.Card,{style:{marginTop:20}},c("CS_MYAPPLICATIONS_NO_APPLICATION").split("\\n").map((e,t)=>r.createElement("p",{key:t,style:{textAlign:"center"}},e))):(null==u?void 0:u.length)>0&&(v=r.createElement(Gt,{t:c,data:u,columns:[{Header:c("UC_CHALLAN_NUMBER"),Cell:e=>{var t,n;let{row:o}=e;return r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:l.parentRoute+"/challansearch/"+(null===(t=o.original)||void 0===t?void 0:t.challanNo)},null===(n=o.original)||void 0===n?void 0:n.challanNo)))},mobileCell:e=>m(null==e?void 0:e.challanNo)},{Header:c("UC_COMMON_TABLE_COL_PAYEE_NAME"),Cell:e=>{var t;let{row:n}=e;return d(""+(null===(t=n.original)||void 0===t?void 0:t.name))},mobileCell:e=>m(null==e?void 0:e.name)},{Header:c("UC_SERVICE_CATEGORY_LABEL"),Cell:e=>{var t;let{row:n}=e,r=function(e,t,n){if(void 0===e&&(e=""),void 0===t&&(t=""),void 0===n&&(n=""),""==t)return e;for(;e.includes(t);)e=e.replace(t,n);return e}(""+(null===(t=n.original)||void 0===t?void 0:t.businessService),".","_");return r=r.toUpperCase(),d(c("BILLINGSERVICE_BUSINESSSERVICE_"+r))},mobileCell:e=>m("BILLINGSERVICE_BUSINESSSERVICE_"+(null==e?void 0:e.businessService))},{Header:c("UC_RECIEPT_NUMBER_LABEL"),Cell:e=>{var t,n;let{row:r}=e;return null!==(t=r.original)&&void 0!==t&&t.receiptNumber?d(""+(null===(n=r.original)||void 0===n?void 0:n.receiptNumber)):"-"},mobileCell:e=>m(null==e?void 0:e.receiptNumber)||"-"},{Header:c("UC_DUE_DATE"),Cell:e=>{var t,n;let{row:r}=e;const o="NA"===(null===(t=r.original)||void 0===t?void 0:t.dueDate)?c("CS_NA"):p(null===(n=r.original)||void 0===n?void 0:n.dueDate);return d(c(""+o))},mobileCell:e=>m(p(null==e?void 0:e.dueDate))},{Header:c("UC_TOTAL_AMOUNT"),Cell:e=>{var t;let{row:n}=e;return d(c(""+(null===(t=n.original)||void 0===t?void 0:t.totalAmount)))},mobileCell:e=>m(null==e?void 0:e.totalAmount)},{Header:c("UC_COMMON_TABLE_COL_STATUS"),Cell:e=>{var t;let{row:n}=e;return d(c(""+(null===(t=n.original)||void 0===t?void 0:t.applicationStatus)))},mobileCell:e=>{var t,n;return m(null==e||null===(t=e.workflowData)||void 0===t||null===(n=t.state)||void 0===n?void 0:n.state)}},{Header:c("UC_TABLE_COL_ACTION"),Cell:e=>{var t,n;let{row:a}=e,l="ACTIVE";var u,s,f,p,m;return(null===(t=a.original)||void 0===t?void 0:t.totalAmount)>0&&(l="COLLECT"),"COLLECT"==l?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null===(u=a.original)||void 0===u?void 0:u.businessService}/${null===(s=a.original)||void 0===s?void 0:s.challanNo}/tenantId=${null===(f=a.original)||void 0===f?void 0:f.tenantId}?workflow=mcollect`}},c("UC_"+l)))):"PAID"==(null===(n=a.original)||void 0===n?void 0:n.applicationStatus)?r.createElement("div",null,r.createElement("span",{className:"link"},((e,t)=>{const{t:n}=o.useTranslation();return r.createElement("a",{href:"javascript:void(0)",style:{color:"#FE7A51",cursor:"pointer"},onClick:n=>{y(e,t)}}," ",n("UC_DOWNLOAD_RECEIPT")," ")})(null===(p=a.original)||void 0===p?void 0:p.businessService,null===(m=a.original)||void 0===m?void 0:m.challanNo))):d(c("CS_NA"))},mobileCell:e=>{var t,n;return m(null==e||null===(t=e.workflowData)||void 0===t||null===(n=t.state)||void 0===n?void 0:n.state)}}],getCellProps:e=>({style:{minWidth:e.column.Header===c("ES_INBOX_APPLICATION_NO")?"240px":"",padding:"20px 18px",fontSize:"16px",wordBreak:"break-word",overflowWrap:"break-word",width:"250px"}}),onPageSizeChange:l.onPageSizeChange,currentPage:l.currentPage,onNextPage:l.onNextPage,onPrevPage:l.onPrevPage,onLastPage:l.onLastPage,onFirstPage:l.onFirstPage,pageSizeLimit:l.pageSizeLimit,onSort:l.onSort,disableSort:l.disableSort,sortParams:l.sortParams,totalRecords:l.totalRecords})),r.createElement("div",{className:"inbox-container",style:{overflow:"auto"}},!l.isSearch&&r.createElement("div",{className:"filters-container"},r.createElement(Kt,{parentRoute:l.parentRoute,businessService:l.businessService}),r.createElement("div",null,r.createElement(s,{defaultSearchParams:l.defaultSearchParams,onFilterChange:l.onFilterChange,searchParams:l.searchParams,type:"desktop"}))),r.createElement("div",{style:{flex:1}},r.createElement(Yt,{defaultSearchParams:l.defaultSearchParams,onSearch:l.onSearch,type:"desktop",searchFields:l.searchFields,isInboxPage:!(null!=l&&l.isSearch),searchParams:l.searchParams}),r.createElement("div",{className:"result",style:{marginLeft:null!=l&&l.isSearch?"":"24px",flex:1}},v)))},Zt=e=>{let{t:o,data:i,defaultSearchParams:a={},onFilterChange:l,onSearch:u,serviceRequestIdKey:c,isFstpOperator:s,isLoading:f,isSearch:d,searchParams:p,searchFields:m,sortParams:v,linkPrefix:h,filterComponent:g}=e;const[y,_]=n.useState(d?"SEARCH":""),[E,b]=n.useState(!!d),[C,S]=n.useState(v),[L]=n.useState(()=>{var e;return null===(e=Digit.ComponentRegistryService)||void 0===e?void 0:e.getComponent(g)}),[N,A]=n.useState(p);n.useEffect(()=>{y&&b(!0)},[y]);const w=()=>{b(!1),_(""),S(v)};if(f)return r.createElement(t.Loader,null);let x;return i&&0!==(null==i?void 0:i.length)?i&&(null==i?void 0:i.length)>0&&(x=r.createElement(t.DetailsCard,{data:i,serviceRequestIdKey:c,linkPrefix:h||"/digit-ui/employee/mcollect/challansearch/"})):x=r.createElement(t.Card,{style:{marginTop:20}},o("CS_MYAPPLICATIONS_NO_APPLICATION").split("\\n").map((e,t)=>r.createElement("p",{key:t,style:{textAlign:"center"}},e))),r.createElement(r.Fragment,null,r.createElement("div",{className:"searchBox"},u&&r.createElement(t.SearchAction,{text:"SEARCH",handleActionClick:()=>{_("SEARCH"),A({businessService:[],status:[]}),b(!0)}}),!d&&l&&r.createElement(t.FilterAction,{text:"FILTER",handleActionClick:()=>{_("FILTER"),A({businessService:[],status:[]}),b(!0)}})),x,E&&r.createElement(t.PopUp,null,"FILTER"===y&&r.createElement("div",{className:"popup-module"},r.createElement(L,{onFilterChange:e=>{l(e,!0),b(!1)},onRefresh:l,Close:w,type:"mobile",searchParams:N,defaultSearchParams:a})),"SEARCH"===y&&r.createElement("div",{className:"popup-module"},r.createElement(Yt,{type:"mobile",onClose:w,onSearch:u,isFstpOperator:s,searchParams:N,searchFields:m}))))},Qt=e=>{let{businessService:a,allLinks:l,headerText:u}=e;const{t:c}=o.useTranslation(),[s,f]=n.useState([]),{roles:d}=Digit.UserService.getUser().info;return n.useEffect(()=>{let e=l?l.filter(e=>e.businessService===a).filter(e=>{let{roles:t}=e;return t.some(e=>d.map(e=>{let{code:t}=e;return t}).includes(e))||!t.length}):[];f(e)},[]),r.createElement(t.Card,{style:{paddingRight:0,marginTop:0},className:"employeeCard filter"},r.createElement("div",{className:"complaint-links-container"},r.createElement("div",{className:"header",style:{justifyContent:"flex-start"}},r.createElement("span",{className:"logo"},r.createElement(t.ShippingTruck,null))," ",r.createElement("span",{className:"text"},c(u))),r.createElement("div",{className:"body"},s.map((e,t)=>{let{link:n,text:o,hyperlink:a=!1,accessTo:l=[]}=e;return r.createElement("span",{className:"link",key:t},a?r.createElement("a",{href:n},c(o)):r.createElement(i.Link,{to:n},c(o)))}))))},Xt=e=>{let{data:t,defaultSearchParams:n={},isLoading:a,isSearch:l,searchFields:u,onFilterChange:c,onSearch:s,onSort:f,parentRoute:d,searchParams:p,sortParams:m,linkPrefix:v,filterComponent:h}=e;const{t:g}=o.useTranslation(),y=e=>r.createElement("span",{className:"sla-cell"},e);return r.createElement("div",{style:{padding:0}},r.createElement("div",{className:"inbox-container"},r.createElement("div",{className:"filters-container"},!l&&r.createElement(Qt,{linkPrefix:d,allLinks:[{text:g("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application",roles:[]}],headerText:g("ACTION_TEST_MCOLLECT"),isMobile:!0}),r.createElement(Zt,{t:g,data:null==t?void 0:t.map(e=>{const t={};return[{Header:g("UC_CHALLAN_NUMBER"),mobileCell:e=>y(null==e?void 0:e.challanNo)},{Header:g("UC_COMMON_TABLE_COL_PAYEE_NAME"),mobileCell:e=>y(null==e?void 0:e.name)},{Header:g("UC_SERVICE_CATEGORY_LABEL"),mobileCell:e=>{let t=function(e,t,n){if(void 0===e&&(e=""),void 0===t&&(t=""),void 0===n&&(n=""),""==t)return e;for(;e.includes(t);)e=e.replace(t,n);return e}(""+(null==e?void 0:e.businessService),".","_");return t=t.toUpperCase(),y(g("BILLINGSERVICE_BUSINESSSERVICE_"+t))}},{Header:g("UC_DUE_DATE"),mobileCell:e=>y("NA"===(null==e?void 0:e.dueDate)?g("CS_NA"):(e=>{if(null==e||null==e||""==e)return"NA";const t=new Date(e);let n=t.getMonth()+1,r=t.getDate();return n=(n>9?"":"0")+n,r=(r>9?"":"0")+r,`${r}/${n}/${t.getFullYear()}`})(null==e?void 0:e.dueDate))},{Header:g("UC_RECIEPT_NUMBER_LABEL"),mobileCell:e=>y(null===(null==e?void 0:e.receiptNumber)?g("CS_NA"):null==e?void 0:e.receiptNumber)},{Header:g("UC_TOTAL_AMOUNT"),mobileCell:e=>y(null==e?void 0:e.totalAmount)},{Header:g("UC_COMMON_TABLE_COL_STATUS"),mobileCell:e=>y(null==e?void 0:e.applicationStatus)},{Header:g("UC_TABLE_COL_ACTION"),mobileCell:e=>{let t="ACTIVE";return(null==e?void 0:e.totalAmount)>0&&(t="COLLECT"),"COLLECT"==t?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null==e?void 0:e.businessService}/${null==e?void 0:e.challanNo}/tenantId=${null==e?void 0:e.tenantId}?workflow=mcollect`}},g("UC_"+t)))):"PAID"==(null==e?void 0:e.applicationStatus)?r.createElement("div",null,r.createElement("span",{className:"link"},r.createElement(i.Link,null,r.createElement("a",{href:"javascript:void(0)",style:{color:"#FE7A51",cursor:"pointer"},onClick:t=>{!function(e,t){try{const n=Digit.ULBService.getCurrentTenantId(),r=Digit.ULBService.getStateId();Promise.resolve(Digit.PaymentService.getReciept(n,e,{consumerCodes:t})).then(function(e){var t;function n(){return Promise.resolve(Digit.PaymentService.printReciept(r,{fileStoreIds:o.filestoreIds[0]})).then(function(e){window.open(e[o.filestoreIds[0]],"_blank")})}let o={filestoreIds:[null===(t=e.Payments[0])||void 0===t?void 0:t.fileStoreId]};const i=function(t){if(null===(t=e.Payments[0])||void 0===t||!t.fileStoreId)return Promise.resolve(Digit.PaymentService.generatePdf(r,{Payments:e.Payments},"consolidatedreceipt")).then(function(e){o=e})}();return i&&i.then?i.then(n):n()})}catch(e){return Promise.reject(e)}}(null==e?void 0:e.businessService,null==e?void 0:e.challanNo)}}," ",g("UC_DOWNLOAD_RECEIPT")," ")))):y(g("CS_NA"))}}].forEach(n=>{n.mobileCell&&(t[n.Header]=n.mobileCell(e))}),t}),defaultSearchParams:n,onFilterChange:c,isLoading:a,isSearch:l,onSearch:s,onSort:f,searchParams:p,searchFields:u,linkPrefix:v,sortParams:m,serviceRequestIdKey:e=>{var t,n;return null==e||null===(t=e[g("UC_CHALLAN_NUMBER")])||void 0===t||null===(n=t.props)||void 0===n?void 0:n.children},filterComponent:h}))))},en=e=>{var i,a,l,u,c,s;let{parentRoute:f,businessService:d="PT",initialStates:p={},filterComponent:m,isInbox:v}=e;const h=Digit.ULBService.getCurrentTenantId();let g=Digit.SessionStorage.get("isMcollectAppChanged");const{t:y}=o.useTranslation(),[_,E]=n.useState(p.pageOffset||0),[b,C]=n.useState(p.pageSize||10),[S,L]=n.useState(p.sortParams||[{id:"createdTime",desc:!1}]),[N,A]=(Digit.Hooks.mcollect.useMCollectCount(h),n.useState(()=>p.searchParams||{})),[w,x]=n.useState({}),[I,T]=n.useState(!0);let D=window.Digit.Utils.browser.isMobile(),O=D?{limit:100,offset:0,sortOrder:null!=S&&null!==(i=S[0])&&void 0!==i&&i.desc?"DESC":"ASC"}:{limit:b,offset:_,sortOrder:null!=S&&null!==(a=S[0])&&void 0!==a&&a.desc?"DESC":"ASC"};const{isLoading:R,data:P,...k}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:h,filters:{...N,...O},isMcollectAppChanged:g});console.log("mcollect data: ",P),console.log("hookloading",R),console.log("data challan",(null==P||null===(l=P.challans)||void 0===l?void 0:l.length)>0),console.log(!R&&(null==P||null===(u=P.challans)||void 0===u?void 0:u.length)>0),n.useEffect(()=>{var e,t;!R&&!(null!=P&&null!==(e=P.challans)&&void 0!==e&&e.length)>0?T(!1):(R||null!=P&&null!==(t=P.challans)&&void 0!==t&&t.length)&&T(!0)},[R,P]),console.log("isLoader",I);let B,U=[],M={};n.useEffect(()=>{var e;null!=P&&P.challans&&(null==P||null===(e=P.challans)||void 0===e?void 0:e.length)>0&&(T(!0),function(){try{var e;function t(){T(!1),x(M)}let n={},r=[],o=[];null==P||null===(e=P.challans)||void 0===e||e.forEach(e=>{o=n[e.businessService]||[],r=o,"ADVT.Canopy_Fee"!==e.businessService&&(o.push(e.challanNo),n[e.businessService]=o)});let i=[];const a=function(e,t,r){var o=[];for(var a in e)o.push(a);return function(e,t,n){var r,o,i=-1;return function n(a){try{for(;++i<e.length;)if((a=t(i))&&a.then){if(!((l=a)instanceof Wt&&1&l.s))return void a.then(n,o||(o=qt.bind(null,r=new Wt,2)));a=a.v}r?qt(r,1,a):r=a}catch(e){qt(r||(r=new Wt),2,e)}var l}(),r}(o,function(e){return function(e){let t=n[e].toString();return Promise.resolve(Digit.PaymentService.fetchBill(h,{consumerCode:t,businessService:e})).then(function(e){B=e,i=i.concat(B.Bill),M={},i.filter(e=>null==e?void 0:e.businessService).forEach(e=>{var t,n;M[null==e?void 0:e.consumerCode]={businessService:null==e?void 0:e.businessService,otalAmount:(null==e||null===(t=e.billDetails[0])||void 0===t?void 0:t.totalAmount)||0,dueDate:null==e||null===(n=e.billDetails[0])||void 0===n?void 0:n.expiryDate}})})}(o[e])})}(n);Promise.resolve(a&&a.then?a.then(t):t())}catch(e){return Promise.reject(e)}}())},[P]),console.log("isLoader 2",I),null==P||null===(c=P.challans)||void 0===c||c.map(e=>{var t,n,r;U.push({challanNo:null==e?void 0:e.challanNo,name:null==e||null===(t=e.citizen)||void 0===t?void 0:t.name,applicationStatus:null==e?void 0:e.applicationStatus,businessService:null==e?void 0:e.businessService,totalAmount:(null===(n=w[e.challanNo])||void 0===n?void 0:n.totalAmount)||0,dueDate:(null===(r=w[e.challanNo])||void 0===r?void 0:r.dueDate)||"NA",tenantId:null==e?void 0:e.tenantId,receiptNumber:null==e?void 0:e.receiptNumber})}),n.useEffect(()=>{E(0)},[N]);const j=e=>{let t=e.delete,n={};n=D?{...e}:{...N,...e},t&&t.forEach(e=>delete n[e]),delete n.delete,delete e.delete,A({...n})},F=n.useCallback(e=>{0!==e.length&&L(e)},[]),H=()=>[{label:y("UC_CHALLAN_NUMBER"),name:"challanNo"},{label:y("UC_MOBILE_NUMBER_LABEL"),name:"mobileNumber",maxlength:10,pattern:"[6-9][0-9]{9}",title:y("ES_SEARCH_APPLICATION_MOBILE_INVALID"),componentInFront:"+91"},{label:y("UC_RECIEPT_NUMBER_LABEL"),name:"receiptNumber"}];if(null!==(null==k||null===(s=k.data)||void 0===s?void 0:s.length))return D?r.createElement(Xt,{data:U,defaultSearchParams:p.searchParams,isLoading:R,isSearch:!v,searchFields:H(),onFilterChange:j,onSearch:j,onSort:F,parentRoute:f,searchParams:N,sortParams:S,tableConfig:null==k?void 0:k.tableConfig,filterComponent:m}):r.createElement("div",null,v&&r.createElement(t.Header,null,y("UC_SEARCH_MCOLLECT_HEADER")),r.createElement(Jt,{businessService:d,data:U,tableConfig:null==k?void 0:k.tableConfig,isLoading:R,defaultSearchParams:p.searchParams,isSearch:!v,onFilterChange:j,searchFields:H(),onSearch:j,onSort:F,onNextPage:()=>{E(e=>e+b)},onPrevPage:()=>{E(e=>e-b)},onLastPage:()=>{E((null==P?void 0:P.totalCount)&&10*Math.ceil((null==P?void 0:P.totalCount)/10)-b)},onFirstPage:()=>{E(e=>0)},currentPage:Math.floor(_/b),pageSizeLimit:b,disableSort:!1,onPageSizeChange:e=>{C(Number(e.target.value))},parentRoute:f,searchParams:N,sortParams:S,totalRecords:null==P?void 0:P.totalCount,filterComponent:m,isLoader:I}))},tn=e=>{var n,a,l,u,c,s,f,d;let{path:p,url:m,userType:v}=e;const{t:h}=o.useTranslation(),g=i.useLocation(),y=innerWidth<=640,_={searchParams:{status:[],businessService:[]}},E=[{combineTaxDueInSearchData:function(e,t,n){try{function r(){return n(t)}let t;const o=Digit.ULBService.getCurrentTenantId();let i=["PT"].join(),a=e.map(e=>e.propertyId).join();const l=function(n,r){try{var l=Promise.resolve(Digit.PaymentService.fetchBill(o,{consumerCode:a,businessService:i})).then(function(n){let r={};n.Bill.forEach(e=>{r[e.consumerCode]=e.totalAmount}),t=e.map(e=>({...e,due_tax:"₹ "+(r[e.propertyId]||0)}))})}catch(e){return r(e)}return l&&l.then?l.then(void 0,r):l}(0,function(n){var r,o;const i=null==n||null===(r=n.response)||void 0===r?void 0:r.data;["EG_BS_BILL_NO_DEMANDS_FOUND","EMPTY_DEMANDS"].includes(null==i||null===(o=i.Errors)||void 0===o?void 0:o[0].code)&&(t=e.map(e=>({...e,due_tax:"₹ 0"})))});return Promise.resolve(l&&l.then?l.then(r):r())}catch(e){return Promise.reject(e)}}}],b=null===(n=Digit)||void 0===n||null===(a=n.ComponentRegistryService)||void 0===a?void 0:a.getComponent("MCollectEmployeeChallan"),C=null===(l=Digit)||void 0===l||null===(u=l.ComponentRegistryService)||void 0===u?void 0:u.getComponent("MCollectAcknowledgement"),S=null===(c=Digit)||void 0===c||null===(s=c.ComponentRegistryService)||void 0===s?void 0:s.getComponent("MCollectEditChallan"),L=null===(f=Digit)||void 0===f||null===(d=f.ComponentRegistryService)||void 0===d?void 0:d.getComponent("MCollectNewChallan");return r.createElement(i.Switch,null,r.createElement(r.Fragment,null,r.createElement("div",{className:"ground-container"},r.createElement("p",{className:"breadcrumb employee-main-application-details",style:{marginLeft:y?"2vw":"revert"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{cursor:"pointer",color:"#666"}},h("ES_COMMON_HOME"))," ","/ ",r.createElement("span",null,h("/digit-ui/employee/mcollect/inbox"===g.pathname?"UC_SEARCH_HEADER":"UC_COMMON_HEADER_SEARCH"))),r.createElement(t.PrivateRoute,{exact:!0,path:p+"/",component:()=>r.createElement(ln,{matchPath:p,userType:v})}),r.createElement(t.PrivateRoute,{path:p+"/inbox",component:()=>r.createElement(en,{parentRoute:p,businessService:"PT",filterComponent:"MCOLLECT_INBOX_FILTER",initialStates:_,isInbox:!0})})," ",r.createElement(t.PrivateRoute,{path:p+"/new-application",component:()=>r.createElement(L,{parentUrl:m})}),r.createElement(t.PrivateRoute,{path:p+"/search",component:()=>r.createElement(en,{parentRoute:p,businessService:"PT",middlewareSearch:E,initialStates:_,isInbox:!1})}),r.createElement(t.PrivateRoute,{path:p+"/acknowledgement",component:()=>r.createElement(C,null)}),r.createElement(t.PrivateRoute,{path:p+"/challansearch/:challanno",component:()=>r.createElement(b,null)}),r.createElement(t.PrivateRoute,{path:p+"/modify-challan/:challanNo",component:()=>r.createElement(S,null)})," ")))},{forwardRef:nn}=r,rn=(nn((e,i)=>{let l=e.setFormData;const{register:u,handleSubmit:c,errors:s,setValue:f}=a.useForm(),{t:d}=o.useTranslation();n.useEffect(()=>{if(l){const e=Object.keys(l);l&&e.map(e=>f(""+e,""+(null==l[""+e]?"":l[""+e])))}},[l]),l&&(f("name",""+l.name),f("mobileNumber",""+l.mobileNumber),f("doorNo",""+l.doorNo),f("buildingName",""+l.buildingName),f("street",""+l.street),f("pincode",""+(null===l.pincode?"":l.pincode)),f("comments",""+l.comments));const p=(e,n)=>{switch(e){case"text":return r.createElement("div",{className:"field-container"},n.componentInFront?n.componentInFront:null,r.createElement(t.TextInput,N({className:"field desktop-w-full"},n,{inputRef:u(n.validation)})));case"textarea":return r.createElement(t.TextArea,N({className:"field desktop-w-full",name:n.name||""},n,{inputRef:u(n.validation)}));case"custom":return r.createElement(TaxForm,N({register:u},n,{errors:s}));default:return!1!==n.dependency?n:null}},m=n.useMemo(()=>{var n;return null===(n=e.config)||void 0===n?void 0:n.map((n,o,i)=>r.createElement(r.Fragment,{key:o},r.createElement(t.CardSectionHeader,null,n.head),n.body.map((n,o)=>{var i;return r.createElement(r.Fragment,{key:o},n.label?r.createElement(t.LabelFieldPair,null,r.createElement(t.CardLabel,null,n.label,n.isMandatory?" * ":null),r.createElement("div",{className:"field"},p(n.type,n.populators))):r.createElement("div",{className:"field"},p(n.type,n.populators)),e.errors[n.populators.name]&&(null===(i=n.populators)||void 0===i||!i.validate||s[n.populators.validate])&&r.createElement(t.CardLabelError,{style:{width:"70%",marginLeft:"30%",fontSize:"12px",marginTop:"-21px"}},n.populators.error))}),i.length-1===o?null:r.createElement(t.BreakLine,null)))},[e.config,s]),v=e.isDisabled||!1;return r.createElement("form",{onSubmit:c(function(t){e.onSubmit(t)})},r.createElement(t.Card,null,r.createElement(t.CardSubHeader,null,e.heading),m,e.children,r.createElement(t.ActionBar,null,r.createElement(t.SubmitBar,{disabled:v,label:d(e.label),submit:"submit"}))))}),[{head:"",body:[{type:"component",component:"ConsumerDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]},{head:"",body:[{type:"component",component:"AddressDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]},{head:"",body:[{type:"component",component:"ServiceDetails",key:"consomerDetails1",withoutLabel:!0,hideInCitizen:!0}]}]),on=e=>{var a;let{ChallanData:l}=e;const u=Digit.ULBService.getCurrentTenantId(),{t:c}=o.useTranslation(),{url:s}=i.useRouteMatch();let f=!1;s.includes("modify-challan")&&(f=!0);const[d,m]=n.useState(!1),v=i.useHistory(),[h,g,y]=Digit.Hooks.useSessionStorage("store-data",null),[_,E,b]=Digit.Hooks.useSessionStorage("EMPLOYEE_MUTATION_HAPPENED",!1),[C,S,L]=Digit.Hooks.useSessionStorage("EMPLOYEE_MUTATION_SUCCESS_DATA",{}),[N,A]=n.useState(!1),[w,x]=(window.Digit.Utils.browser.isMobile(),n.useState(null)),[I,T]=n.useState(null),D=Digit.ULBService.getStateId();let{data:O}=Digit.Hooks.mcollect.useMcollectFormConfig.getFormConfig(D,{}),R=l?l[0].auditDetails.lastModifiedTime:null;const{data:P}=l?Digit.Hooks.useFetchBillsForBuissnessService({businessService:l[0].businessService,consumerCode:l[0].challanNo},{lastModTime:R}):{};n.useEffect(()=>{if(f&&P){let e=((e,t)=>{var n,r,o,i,a,l;let u={ConsumerName:e[0].citizen.name,mobileNumber:e[0].citizen.mobileNumber,emailId:e[0].citizen.emailId,doorNo:e[0].address.doorNo,building:e[0].address.buildingName,streetName:e[0].address.street,pincode:e[0].address.pincode||"143001",mohalla:{...e[0].address.locality,i18nkey:`${p(e[0].tenantId,".","_").toUpperCase()}_ADMIN_${null===(n=e[0])||void 0===n||null===(r=n.address)||void 0===r||null===(o=r.locality)||void 0===o?void 0:o.code}`},category:{code:e[0].businessService,i18nkey:"BILLINGSERVICE_BUSINESSSERVICE_"+(null===(i=e[0])||void 0===i?void 0:i.businessService.split(".")[0].toUpperCase())},categoryType:{code:e[0].businessService,i18nkey:"BILLINGSERVICE_BUSINESSSERVICE_"+p(e[0].businessService,".","_").toUpperCase()},fromDate:e[0]?new Date(e[0].taxPeriodFrom).getFullYear().toString()+"-"+`${new Date(e[0].taxPeriodFrom).getMonth()+1<10?"0":""}${new Date(e[0].taxPeriodFrom).getMonth()+1}-`+`${new Date(e[0].taxPeriodFrom).getDate()<10?"0":""}${new Date(e[0].taxPeriodFrom).getDate()}`:null,toDate:e[0]?new Date(e[0].taxPeriodTo).getFullYear().toString()+"-"+`${new Date(e[0].taxPeriodTo).getMonth()+1<10?"0":""}${new Date(e[0].taxPeriodTo).getMonth()+1}-`+`${new Date(e[0].taxPeriodTo).getDate()<10?"0":""}${new Date(e[0].taxPeriodTo).getDate()}`:null};return u[""+(null===(a=e[0])||void 0===a?void 0:a.businessService.split(".")[0])]={},t.Bill[0].billDetails[0].billAccountDetails.length>0&&t.Bill[0].billDetails[0].billAccountDetails.map(t=>{var n;return u[""+(null===(n=e[0])||void 0===n?void 0:n.businessService.split(".")[0])][""+t.taxHeadCode.split(".")[1]]=""+t.amount}),sessionStorage.setItem("InitialTaxFeilds",JSON.stringify(u[""+(null===(l=e[0])||void 0===l?void 0:l.businessService.split(".")[0])])),u})(l,P);A(!0),sessionStorage.setItem("mcollectEditObject",JSON.stringify({consomerDetails1:[{...e}]}))}},[f,P]),n.useEffect(()=>{E(!1),L()},[]),window.onunload=function(){sessionStorage.removeItem("mcollectFormData")};let k=O||[];return O=O||rn,null===(a=O)||void 0===a||a.map(e=>{"ES_NEW_APPLICATION_PROPERTY_ASSESSMENT"!==e.head&&e.head&&k.push(e)}),k=O,r.createElement("div",null,!f||JSON.parse(sessionStorage.getItem("mcollectEditObject"))||N?r.createElement(t.FormComposer,{heading:c(f?"UC_UPDATE_CHALLAN":"UC_COMMON_HEADER"),label:c("ES_COMMON_APPLICATION_SUBMIT"),config:k.map(e=>{return{...e,body:e.body.filter(e=>!e.hideInEmployee),head:(t=e.head,"ES_NEW_APPLICATION_LOCATION_DETAILS"===t?"TL_CHECK_ADDRESS":"ES_NEW_APPLICATION_OWNERSHIP_DETAILS"===t?"TL_OWNERSHIP_DETAILS_HEADER":t)};var t}),fieldStyle:{marginRight:0},onSubmit:e=>{var t,n,r,o,i,a,c,d,p,m,h,g,y,_;let E=JSON.parse(sessionStorage.getItem("mcollectFormData")),b=(e=E||(null===(t=e)||void 0===t||null===(n=t.consomerDetails1)||void 0===n?void 0:n[0]))[""+(null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0])]?Object.keys(e[""+(null===(a=e)||void 0===a||null===(c=a.category)||void 0===c||null===(d=c.code)||void 0===d?void 0:d.split(".")[0])]):[],C=e[""+(null===(p=e)||void 0===p||null===(m=p.category)||void 0===m||null===(h=m.code)||void 0===h?void 0:h.split(".")[0])]?Object.values(e[""+(null===(g=e)||void 0===g||null===(y=g.category)||void 0===y||null===(_=y.code)||void 0===_?void 0:_.split(".")[0])]):[],S={};var L,N,A,w,I,T,D,O,R,P,k,B;S=f?{accountId:l[0].accountId,citizen:l[0].citizen,applicationStatus:l[0].applicationStatus,auditDetails:l[0].auditDetails,id:l[0].id,businessService:l[0].businessService,challanNo:l[0].challanNo,consumerType:null===(L=e)||void 0===L||null===(N=L.category)||void 0===N?void 0:N.code,description:e.comments,taxPeriodFrom:Date.parse(e.fromDate),taxPeriodTo:Date.parse(e.toDate),tenantId:u,address:l[0].address,amount:b.map((t,n)=>{var r,o,i;return{taxHeadCode:`${null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0]}.${t}`,amount:C[n]?Math.round(C[n]):0}})}:{citizen:{name:e.ConsumerName,mobileNumber:e.mobileNumber,emailId:e.emailId},businessService:null===(A=e)||void 0===A||null===(w=A.categoryType)||void 0===w?void 0:w.code,consumerType:null===(I=e)||void 0===I||null===(T=I.category)||void 0===T||null===(D=T.code)||void 0===D?void 0:D.split(".")[0],description:null===(O=e)||void 0===O?void 0:O.comments,taxPeriodFrom:Date.parse(null===(R=e)||void 0===R?void 0:R.fromDate),taxPeriodTo:Date.parse(null===(P=e)||void 0===P?void 0:P.toDate),tenantId:u,address:{buildingName:e.building,doorNo:e.doorNo,street:e.streetName,locality:{code:null===(k=e)||void 0===k||null===(B=k.mohalla)||void 0===B?void 0:B.code},pincode:e.pincode},amount:b.map((t,n)=>{var r,o,i;return{taxHeadCode:`${null===(r=e)||void 0===r||null===(o=r.category)||void 0===o||null===(i=o.code)||void 0===i?void 0:i.split(".")[0]}.${t}`,amount:C[n]?Math.round(C[n]):0}})},f?Digit.MCollectService.update({Challan:S},u).then((e,t)=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];sessionStorage.removeItem("mcollectEditObject"),Digit.SessionStorage.set("isMcollectAppChanged",t.auditDetails.lastModifiedTime),Digit.MCollectService.generateBill(t.challanNo,u,t.businessService,"challan").then(e=>{e.Bill&&e.Bill.length>0&&v.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${u}&billNumber=${e.Bill[0].billNumber}&serviceCategory=${e.Bill[0].businessService}&challanNumber=${e.Bill[0].consumerCode}&isEdit=true`,{from:s})})}}).catch(e=>{var t,n;return x({key:"error",label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})}):Digit.MCollectService.create({Challan:S},u).then((e,t)=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];sessionStorage.removeItem("mcollectFormData"),Digit.MCollectService.generateBill(t.challanNo,u,t.businessService,"challan").then(e=>{e.Bill&&e.Bill.length>0&&v.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${u}&billNumber=${e.Bill[0].billNumber}&serviceCategory=${e.Bill[0].businessService}&challanNumber=${e.Bill[0].consumerCode}`,{from:s})})}}).catch(e=>{var t,n;x({key:"error",label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})})},defaultValues:{},onFormValueChange:(e,t,n)=>{m(!Object.keys(n.errors).length)},breaklineStyle:{border:"0px"}}):r.createElement(t.Loader,null),w&&r.createElement(t.Toast,{error:"error"===(null==w?void 0:w.key),label:null==w?void 0:w.label,onClose:()=>{x(null),T(null)}}))},an=e=>{let{stateCode:n,userType:o,tenants:a}=e;const l=Digit.StoreData.getCurrentLanguage(),{isLoading:u}=Digit.Services.useStore({stateCode:n,moduleCode:"UC",language:l});if(Digit.SessionStorage.set("MCollect_TENANTS",a),u)return r.createElement(t.Loader,null);const{path:c,url:s}=i.useRouteMatch();return"employee"===o?r.createElement(tn,{path:c,url:s,userType:o}):r.createElement(de,null)},ln=e=>{let{matchPath:i}=e;const{t:a}=o.useTranslation(),[l,u,c]=Digit.Hooks.useSessionStorage("PT_CREATE_PROPERTY112",{});n.useEffect(()=>{c()},[]);const s=[{link:i+"/search",i18nKey:a("UC_SEARCH_AND_PAY")},{link:i+"/My-Challans",i18nKey:a("UC_MY_CHALLANS")}];return r.createElement(t.CitizenHomeCard,{header:a("ACTION_TEST_MCOLLECT"),links:s,Icon:()=>r.createElement(t.PTIcon,{className:"fill-path-primary-main"})})},un={ConsumerDetails:e=>{var t,a,l;let{config:u,onSelect:c,formData:s,setError:f,formState:d,clearErrors:p}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(s=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:m}=o.useTranslation(),{pathname:v}=i.useLocation(),h=v.includes("/modify-challan/"),[g,y]=n.useState((null===(t=s)||void 0===t?void 0:t.consomerDetails1)||[{ConsumerName:"",mobileNumber:"",emailId:""}]),[_,E]=n.useState({index:-1,type:""}),[b,C]=(Digit.ULBService.getCurrentTenantId(),Digit.ULBService.getStateId(),n.useState(!1)),S=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID");Digit.Hooks.mcollect.useCommonMDMS(S,"common-masters",["HierarchyType"]),n.useEffect(()=>{const e=g.map(e=>e);c(null==u?void 0:u.key,e)},[g]);const L={focusIndex:_,allOwners:g,setFocusIndex:E,formData:s,formState:d,t:m,setError:f,clearErrors:p,config:u,setconsumerDetails:y,isEdit:h,setIsErrors:C,isErrors:b,consumerDetails:g};return r.createElement(r.Fragment,null,g.map((e,t)=>r.createElement(ce,N({key:e.key,index:t,consumerdetail:e},L))))},ServiceDetails:e=>{var t,a,l,u;let{config:c,onSelect:s,formData:f,setError:d,formState:p,clearErrors:m}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(f=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:v}=o.useTranslation(),{pathname:h}=i.useLocation(),g=h.includes("/modify-challan/"),y=Digit.Hooks.mcollect.usemcollectTenants(),_=()=>(null==y?void 0:y.filter(e=>e.code===Digit.ULBService.getCurrentTenantId()))||[],[E,b]=n.useState((null===(t=f)||void 0===t?void 0:t.consomerDetails1)||[se(_)]),[C,S]=n.useState({index:-1,type:""}),L=Digit.ULBService.getCurrentTenantId(),[A,w]=(Digit.ULBService.getStateId(),n.useState(!1)),x=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID"),I=Digit.Hooks.mcollect.useCommonMDMS(x,"common-masters",["HierarchyType"]),T=I&&I.data&&I.data["common-masters"]&&I.data["common-masters"].HierarchyType&&I.data["common-masters"].HierarchyType[0],[D,O]=n.useState(""),[R,P]=n.useState(""),[k,B]=n.useState([]),{Categories:U,data:M}=Digit.Hooks.mcollect.useMCollectCategory(L,"[?(@.type=='Adhoc' && @.isActive==true)]"),{data:j}=Digit.Hooks.useBoundaryLocalities(null===(u=_()[0])||void 0===u?void 0:u.code,T&&T.code.toLowerCase(),{enabled:!!_()[0]},v),[F,H]=n.useState(j),[$,z]=n.useState(!1),[V,W]=n.useState(_()[0]?_()[0]:"");n.useEffect(()=>{H(j)},[j]),n.useEffect(()=>{const e=E.map(e=>e);s(null==c?void 0:c.key,e)},[E]);const q={focusIndex:C,allOwners:E,setFocusIndex:S,formData:f,formState:p,t:v,setError:d,clearErrors:m,config:c,setconsumerDetails:b,setSelectedLocality:P,categoriesandTypes:M,localities:F,setPincode:O,getCities:_,selectedCity:V,categoires:U,setLocalities:H,setPincodeNotValid:z,isEdit:g,setIsErrors:w,isErrors:A,TaxHeadMaster:k,setSelectedCity:W,pincode:D,cities:y,fetchedLocalities:j,consumerDetails:E};return r.createElement(r.Fragment,null,E.map((e,t)=>r.createElement(fe,N({key:e.key,index:t,consumerdetail:e},q))))},AddressDetails:e=>{var t,a,l,u;let{config:c,onSelect:s,formData:f,setError:d,formState:p,clearErrors:m}=e;window.location.href.includes("modify-challan")&&sessionStorage.getItem("mcollectEditObject")&&(f=JSON.parse(sessionStorage.getItem("mcollectEditObject")));const{t:v}=o.useTranslation(),{pathname:h}=i.useLocation(),g=h.includes("/modify-challan/"),y=Digit.Hooks.mcollect.usemcollectTenants(),_=()=>(null==y?void 0:y.filter(e=>e.code===Digit.ULBService.getCurrentTenantId()))||[],[E,b]=n.useState((null===(t=f)||void 0===t?void 0:t.consomerDetails1)||[le(_)]),[C,S]=n.useState({index:-1,type:""}),[L,A]=(Digit.ULBService.getCurrentTenantId(),Digit.ULBService.getStateId(),n.useState(!1)),w=null===(a=window)||void 0===a||null===(l=a.globalConfigs)||void 0===l?void 0:l.getConfig("STATE_LEVEL_TENANT_ID"),x=Digit.Hooks.mcollect.useCommonMDMS(w,"common-masters",["HierarchyType"]),I=x&&x.data&&x.data["common-masters"]&&x.data["common-masters"].HierarchyType&&x.data["common-masters"].HierarchyType[0],[T,D]=n.useState(""),[O,R]=n.useState(""),{data:P}=Digit.Hooks.useBoundaryLocalities(null===(u=_()[0])||void 0===u?void 0:u.code,I&&I.code.toLowerCase(),{enabled:!!_()[0]},v),[k,B]=n.useState(P),[U,M]=n.useState(!1),[j,F]=n.useState(_()[0]?_()[0]:"");n.useEffect(()=>{B(P)},[P]),n.useEffect(()=>{const e=E.map(e=>e);s(null==c?void 0:c.key,e)},[E]);const H={focusIndex:C,allOwners:E,setFocusIndex:S,formData:f,formState:p,t:v,setError:d,clearErrors:m,config:c,setconsumerDetails:b,setSelectedLocality:R,localities:k,setPincode:D,getCities:_,selectedCity:j,setLocalities:B,setPincodeNotValid:M,isEdit:g,setIsErrors:A,isErrors:L,setSelectedCity:F,pincode:T,cities:y,fetchedLocalities:P,consumerDetails:E};return r.createElement(r.Fragment,null,E.map((e,t)=>r.createElement(ue,N({key:e.key,index:t,consumerdetail:e},H))))},MCollectCard:()=>{var e;if(!Digit.Utils.mCollectAccess())return null;const{t:n}=o.useTranslation(),i=Digit.ULBService.getCurrentTenantId(),{isLoading:a,data:l,...u}=Digit.Hooks.mcollect.useMCollectCount(i),c={Icon:r.createElement(t.PTIcon,null),moduleName:n("UC_COMMON_HEADER_SEARCH"),kpis:[{count:a?"-":null==l||null===(e=l.ChallanCount)||void 0===e?void 0:e.totalChallan,label:n("TOTAL_CHALLANS")}],links:[{label:n("UC_SEARCH_CHALLAN_LABEL"),link:"/digit-ui/employee/mcollect/inbox"},{label:n("UC_GENERATE_NEW_CHALLAN"),link:"/digit-ui/employee/mcollect/new-application"}]};return r.createElement(t.EmployeeModuleCard,c)},MCollectModule:an,MCollectLinks:ln,MCollectEmployeeChallan:e=>{var a,l,u,c,s,f;const{t:d}=o.useTranslation(),{challanno:v}=i.useParams(),h=Digit.ULBService.getCurrentTenantId(),[_,E]=n.useState([]),[b,C]=n.useState(0),[S,N]=n.useState(!1),[A,w]=n.useState(!1),[x,I]=n.useState(null),T=i.useHistory(),{url:D}=i.useRouteMatch(),[O,R]=n.useState(!1),[P,k]=n.useState(null);n.useEffect(()=>{switch(x){case"CANCEL_CHALLAN":return w(!0);case"UPDATE_CHALLAN":return T.push("/digit-ui/employee/mcollect/modify-challan/"+v);case"BUTTON_PAY":return T.push(`/digit-ui/employee/payment/collect/${null==F?void 0:F.businessService}/${v}/tenantId=${h}?workflow=mcollect`)}},[x]);const B=()=>{I(null),w(!1)};let U=Digit.SessionStorage.get("isMcollectAppChanged");const{data:M,...j}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:h,filters:{challanNo:v},isMcollectAppChanged:U});var F=null==M||null===(a=M.challans)||void 0===a?void 0:a.filter(function(e){return e.challanNo===v})[0];let H=[];n.useEffect(()=>{var e;null!=M&&M.challans&&(null==M||null===(e=M.challans)||void 0===e?void 0:e.length)>0&&function(){try{var e,t;H=[],Promise.resolve(Digit.PaymentService.searchBill(h,{consumerCode:null==M||null===(e=M.challans[0])||void 0===e?void 0:e.challanNo,service:null==M||null===(t=M.challans[0])||void 0===t?void 0:t.businessService})).then(function(e){var t,n,r,o;null==e||null===(t=e.Bill[0])||void 0===t||null===(n=t.billDetails[0])||void 0===n||null===(r=n.billAccountDetails)||void 0===r||r.map(e=>{H.push(e)}),C(null==e||null===(o=e.Bill[0])||void 0===o?void 0:o.totalAmount),H&&H.map(e=>{e.taxHeadCode.includes("CGST")?e.order=3:e.taxHeadCode.includes("SGST")&&(e.order=4)}),H.sort((e,t)=>e.order-t.order),E(H)})}catch(e){return Promise.reject(e)}}()},[M]);const $={order:1,label:d("UC_CHALLAN"),onClick:()=>g(v)},z={order:2,label:d("Receipt"),onClick:()=>y(null==F?void 0:F.businessService,v)},V=["CANCEL_CHALLAN","UPDATE_CHALLAN","BUTTON_PAY"];return r.createElement(r.Fragment,null,r.createElement("div",{className:"employee-application-details",style:{marginBottom:"15px"}},r.createElement(t.Header,null,""+d("CHALLAN_DETAILS")," "),r.createElement(t.MultiLink,{className:"multilinkWrapper employee-mulitlink-main-div",onHeadClick:()=>R(!O),displayOptions:O,options:"PAID"===(null==F?void 0:F.applicationStatus)?[$,z]:[$],downloadBtnClassName:"employee-download-btn-className",optionsClassName:"employee-options-btn-className"})),r.createElement("div",null,r.createElement(t.Card,null,r.createElement(t.StatusTable,{style:{padding:"10px 0px"}},r.createElement(t.Row,{label:""+d("UC_CHALLAN_NO"),text:v}),r.createElement("hr",{style:{width:"35%",border:"1px solid #D6D5D4",marginTop:"1rem",marginBottom:"1rem"}}),null==_?void 0:_.map(e=>r.createElement(t.Row,{label:d(p(null==e?void 0:e.taxHeadCode,".","_")),text:"₹"+(null==e?void 0:e.amount)||0,textStyle:{whiteSpace:"pre"}})),r.createElement("hr",{style:{width:"35%",border:"1px solid #D6D5D4",marginTop:"1rem",marginBottom:"1rem"}}),r.createElement(t.Row,{label:r.createElement("b",{style:{padding:"10px 0px"}},d("UC_TOTAL_DUE_AMOUT_LABEL")),text:"₹"+b,textStyle:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}})),r.createElement("div",{style:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}},d("UC_SERVICE_DETAILS_LABEL")),r.createElement(t.StatusTable,null,r.createElement(t.Row,{label:""+d("UC_SERVICE_CATEGORY_LABEL"),text:""+d("BILLINGSERVICE_BUSINESSSERVICE_"+p(null==F||null===(l=F.businessService)||void 0===l?void 0:l.toUpperCase(),".","_")||d("CS_NA")),textStyle:{whiteSpace:"pre"}}),r.createElement(t.Row,{label:""+d("UC_FROM_DATE_LABEL"),text:m(null==F?void 0:F.taxPeriodFrom)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_TO_DATE_LABEL"),text:m(null==F?void 0:F.taxPeriodTo)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_COMMENT_LABEL"),text:""+((null==F?void 0:F.description)||d("CS_NA"))}),r.createElement(t.Row,{label:""+d("CS_INBOX_STATUS_FILTER"),text:d("UC_"+((null==F?void 0:F.applicationStatus)||d("CS_NA")))})),r.createElement("div",{style:{fontSize:"24px",padding:"10px 0px",fontWeight:"700"}},d("UC_CONSUMER_DETAILS_LABEL")),r.createElement(t.StatusTable,null,r.createElement(t.Row,{label:""+d("UC_CONS_NAME_LABEL"),text:(null==F?void 0:F.citizen.name)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_MOBILE_NUMBER"),text:(null==F?void 0:F.citizen.mobileNumber)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_EMAIL_ID"),text:(null==F?void 0:F.citizen.emailId)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_DOOR_NO_LABEL"),text:(null==F?void 0:F.address.doorNo)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_BUILDING_NAME_LABEL"),text:(null==F?void 0:F.address.buildingName)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_STREET_NAME_LABEL"),text:(null==F?void 0:F.address.street)||d("CS_NA")}),r.createElement(t.Row,{label:""+d("UC_MOHALLA_LABEL"),text:""+d(`${p(null==F||null===(u=F.address)||void 0===u||null===(c=u.tenantId)||void 0===c?void 0:c.toUpperCase(),".","_")}_REVENUE_${null==F||null===(s=F.address)||void 0===s||null===(f=s.locality)||void 0===f?void 0:f.code}`||d("CS_NA"))})))),A?r.createElement(L,{t:d,action:x,applicationData:F,billData:_,closeModal:B,submitAction:e=>{Digit.MCollectService.update({Challan:null==e?void 0:e.Challan},h).then(e=>{if(e.challans&&e.challans.length>0){const t=e.challans[0];Digit.SessionStorage.set("isMcollectAppChanged",t.challanNo),T.push(`/digit-ui/employee/mcollect/acknowledgement?purpose=challan&status=success&tenantId=${null==t?void 0:t.tenantId}&serviceCategory=${t.businessService}&challanNumber=${t.challanNo}&applicationStatus=${t.applicationStatus}`,{from:D})}}).catch(e=>{var t,n;return k({key:!0,label:null==e||null===(t=e.response)||void 0===t||null===(n=t.data)||void 0===n?void 0:n.Errors[0].message})}),B()}}):null,P&&r.createElement(t.Toast,{error:P.key,label:d(P.label),onClose:()=>k(null)}),"ACTIVE"==(null==F?void 0:F.applicationStatus)&&r.createElement(t.ActionBar,null,S&&V?r.createElement(t.Menu,{localeKeyPrefix:"UC",options:V,t:d,onSelect:function(e){I(e),N(!1)}}):null,r.createElement(t.SubmitBar,{label:d("ES_COMMON_TAKE_ACTION"),onSubmit:()=>N(!S)})))},MCollectAcknowledgement:()=>{const e=i.useLocation(),[a,l]=n.useState({}),{isEdit:u}=Digit.Hooks.useQueryParams();n.useEffect(()=>{var t;l((t=e.search)?(/^[?#]/.test(t)?t.slice(1):t).split("&").reduce((e,t)=>{let[n,r]=t.split("=");return e[n]=r?decodeURIComponent(r.replace(/\+/g," ")):"",e},{}):{})},[e]);const{t:c}=o.useTranslation(),s=function(){try{return g(null==a?void 0:a.challanNumber,"print"),Promise.resolve()}catch(e){return Promise.reject(e)}};return r.createElement("div",null,"CANCELLED"===(null==a?void 0:a.applicationStatus)?r.createElement(t.Card,null,r.createElement(t.Banner,{message:c("UC_BILL_CANCELLED_SUCCESS_MESSAGE"),applicationNumber:null==a?void 0:a.challanNumber,info:c("UC_CHALLAN_NO"),successful:!0}),r.createElement(t.CardText,null,c("UC_BILL_CANCELLED_SUCCESS_SUB_MESSAGE")),r.createElement("div",{className:"primary-label-btn d-grid",style:{marginLeft:"unset"},onClick:s},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24",viewBox:"0 0 24 24",width:"24"},r.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),r.createElement("path",{d:"M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"})),c("UC_PRINT_CHALLAN_LABEL")),r.createElement(t.ActionBar,{style:{display:"flex",justifyContent:"flex-end",alignItems:"baseline"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{marginRight:"1rem"}},r.createElement(t.SubmitBar,{label:c("CORE_COMMON_GO_TO_HOME")})))):r.createElement(t.Card,null,r.createElement(t.Banner,{message:c(u?"UC_BILL_UPDATED_SUCCESS_MESSAGE":"UC_BILL_GENERATED_SUCCESS_MESSAGE"),applicationNumber:null==a?void 0:a.challanNumber,info:c("UC_CHALLAN_NO"),successful:!0}),r.createElement(t.CardText,null,c("UC_BILL_GENERATION_MESSAGE_SUB")),r.createElement("div",{className:"primary-label-btn d-grid",style:{marginLeft:"unset"},onClick:s},r.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",height:"24",viewBox:"0 0 24 24",width:"24"},r.createElement("path",{d:"M0 0h24v24H0z",fill:"none"}),r.createElement("path",{d:"M19 8H5c-1.66 0-3 1.34-3 3v6h4v4h12v-4h4v-6c0-1.66-1.34-3-3-3zm-3 11H8v-5h8v5zm3-7c-.55 0-1-.45-1-1s.45-1 1-1 1 .45 1 1-.45 1-1 1zm-1-9H6v4h12V3z"})),c("UC_PRINT_CHALLAN_LABEL")),r.createElement(t.ActionBar,{style:{display:"flex",justifyContent:"flex-end",alignItems:"baseline"}},r.createElement(i.Link,{to:"/digit-ui/employee",style:{marginRight:"1rem"}},r.createElement(t.LinkButton,{style:{color:"#FF8C00"},label:c("CORE_COMMON_GO_TO_HOME")})),r.createElement(i.Link,{to:{pathname:`/digit-ui/employee/payment/collect/${null==a?void 0:a.serviceCategory}/${null==a?void 0:a.challanNumber}/tenantId=${null==a?void 0:a.tenantId}?workflow=mcollect`}},r.createElement(t.SubmitBar,{label:c("UC_BUTTON_PAY")})))))},MCollectEditChallan:()=>{const e=Digit.ULBService.getCurrentTenantId();o.useTranslation();let{challanNo:t}=i.useParams(),n=Digit.SessionStorage.get("isMcollectAppChanged");sessionStorage.setItem("isHookRecall",!0);const{isLoading:a,data:l}=Digit.Hooks.mcollect.useMCollectSearch({tenantId:e,filters:{challanNo:t},isMcollectAppChanged:n});return l&&!a?r.createElement(on,{ChallanData:null==l?void 0:l.challans,tenantId:e}):null},MCollectNewChallan:on,MCollectSearchChallanComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>Ht.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[Ht]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement($t,{config:a[0]})))},MCollectSearchResultsComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>zt.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[zt]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement(Vt,{template:a[0].labels,header:a[0].texts.header,actionButtonLabel:a[0].texts.actionButtonLabel,t:e})))},MCollectMyChallanResultsComponent:()=>{const{t:e}=o.useTranslation(),{path:t}=i.useRouteMatch(),a=n.useMemo(()=>pe.map(t=>{const n={};for(const r in t.texts)n[r]=e(t.texts[r]);return{...t,texts:n}},[pe]));return r.createElement(i.Switch,null,r.createElement(i.Route,{path:""+t,exact:!0},r.createElement(Ft,{template:a[0].labels,header:a[0].texts.header,actionButtonLabel:a[0].texts.actionButtonLabel,t:e})))},MCOLLECT_INBOX_FILTER:e=>r.createElement(_,e)};exports.MCollectLinks=ln,exports.MCollectModule=an,exports.initMCollectComponents=()=>{Object.entries(un).forEach(e=>{let[t,n]=e;Digit.ComponentRegistryService.setComponent(t,n)})};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mseva/digit-ui-module-mcollect",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.1",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"description": "Digit Misc Collections Module",
|
|
6
6
|
"main": "dist/index.js",
|
|
@@ -19,7 +19,7 @@
|
|
|
19
19
|
"react-router-dom": "5.3.0"
|
|
20
20
|
},
|
|
21
21
|
"dependencies": {
|
|
22
|
-
"@mseva/digit-ui-react-components"
|
|
22
|
+
"@mseva/digit-ui-react-components": "1.0.1",
|
|
23
23
|
"lodash.merge": "^4.6.2",
|
|
24
24
|
"microbundle-crl": "^0.13.11",
|
|
25
25
|
"react": "17.0.2",
|
|
@@ -28,5 +28,7 @@
|
|
|
28
28
|
"react-i18next": "11.16.2",
|
|
29
29
|
"react-query": "3.6.1",
|
|
30
30
|
"react-router-dom": "5.3.0"
|
|
31
|
-
}
|
|
31
|
+
},
|
|
32
|
+
"devDependencies": {},
|
|
33
|
+
"author": ""
|
|
32
34
|
}
|