sysone-api-mapper 1.0.138 → 1.0.139

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.
@@ -1,2 +1,259 @@
1
- /*! For license information please see index.js.LICENSE.txt */
2
- (()=>{"use strict";var e={n:t=>{var r=t&&t.__esModule?()=>t.default:()=>t;return e.d(r,{a:r}),r},d:(t,r)=>{for(var n in r)e.o(r,n)&&!e.o(t,n)&&Object.defineProperty(t,n,{enumerable:!0,get:r[n]})},o:(e,t)=>Object.prototype.hasOwnProperty.call(e,t),r:e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})}},t={};e.r(t),e.d(t,{apiCall:()=>A,apiMapper:()=>ie,axiosInstance:()=>n,endpoints:()=>E});const r=require("axios"),n=e.n(r)().create({});var o;function i(e){return i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i(e)}function a(e,t,r){return(t=function(e){var t=function(e){if("object"!=i(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==i(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}var u="PARTY_MODULE",l="INTERMEDIARY_MODULE",c="COMMERCIAL_STRUCTURE_MODULE",s="POLICY_MODULE",d="GET",p="POST",m="PUT",E=(a(a(a(a(a(a(a(a(a(a(o={GET_ACTIVITIES:"GET_ACTIVITIES",GET_PRACTICES:"GET_PRACTICES",SEARCH_INDIVIDUALS:"SEARCH_INDIVIDUALS",CREATE_INDIVIDUAL:"CREATE_INDIVIDUAL",GET_IDENTIFICATION_TYPES:"GET_IDENTIFICATION_TYPES",GET_RELATIONS:"GET_RELATIONS",GET_NOTES:"GET_NOTES",GET_FILES:"GET_FILES",GET_SECTORS:"GET_SECTORS",GET_FISCAL_CATEGORIES:"GET_FISCAL_CATEGORIES",GET_MAIL_TYPES:"GET_MAIL_TYPES",GET_PHONE_TYPES:"GET_PHONE_TYPES",UPDATE_NOTES:"UPDATE_NOTES",UPDATE_FILES:"UPDATE_FILES",ADD_RELATION_WITH_EXISTING_PARTY:"ADD_RELATION_WITH_EXISTING_PARTY",GET_RELATIONS_BY_PARTY_CODE:"GET_RELATIONS_BY_PARTY_CODE",REMOVE_RELATION:"REMOVE_RELATION",GET_FILE:"GET_FILE",GET_ORGANIZATION_TYPES:"GET_ORGANIZATION_TYPES",SEARCH_ORGANIZATION:"SEARCH_ORGANIZATION",CREATE_ORGANIZATION:"CREATE_ORGANIZATION",GET_ORGANIZATION_BY_CODE:"GET_ORGANIZATION_BY_CODE",UPDATE_ORGANIZATION:"UPDATE_ORGANIZATION",ADD_RELATION_WITH_NEW_ORGANIZATION:"ADD_RELATION_WITH_NEW_ORGANIZATION",GET_PERSON_BY_CODE:"GET_PERSON_BY_CODE",GET_GENDERS:"GET_GENDERS",GET_MARITAL_STATUSES:"GET_MARITAL_STATUSES",GET_WORKER_TYPES:"GET_WORKER_TYPES",GET_ECONOMIC_CLASSES:"GET_ECONOMIC_CLASSES",SEARCH_PERSON:"SEARCH_PERSON",UPDATE_PERSON:"UPDATE_PERSON",GET_RELATION_TYPES:"GET_RELATION_TYPES",ADD_RELATION_WITH_NEW_PERSON:"ADD_RELATION_WITH_NEW_PERSON",GET_POLICY_PROCESSES:"GET_POLICY_PROCESSES",GET_COUNTRIES:"GET_COUNTRIES",GET_COUNTRY_BY_CODE:"GET_COUNTRY_BY_CODE",GET_PROVINCES:"GET_PROVINCES",GET_CITIES:"GET_CITIES",GET_POSTAL_CODES:"GET_POSTAL_CODES",GET_ADDRESSES_BY_PARTY_CODE:"GET_ADDRESSES_BY_PARTY_CODE",GET_ADDRESS_TYPES:"GET_ADDRESS_TYPES",GET_PAYMENT_METHODS_BY_PARTY_CODE:"GET_PAYMENT_METHODS_BY_PARTY_CODE",GET_CREDIT_CARD_TYPES:"GET_CREDIT_CARD_TYPES",GET_CARD_PROVIDERS:"GET_CARD_PROVIDERS",UPDATE_PAYMENTS:"UPDATE_PAYMENTS",GET_BANKS:"GET_BANKS",GET_CURRENCIES:"GET_CURRENCIES",GET_BANK_ACCOUNT_TYPES:"GET_BANK_ACCOUNT_TYPES",GET_BANK_BRANCHES:"GET_BANK_BRANCHES",GET_PERSON_INTERMEDIARY_BY_CODE:"GET_PERSON_INTERMEDIARY_BY_CODE",GET_ORGANIZATION_INTERMEDIARY_BY_CODE:"GET_ORGANIZATION_INTERMEDIARY_BY_CODE",GET_INTERMEDIARIES_GROUPS:"GET_INTERMEDIARIES_GROUPS",GET_INTERMEDIARIES_ROLES:"GET_INTERMEDIARIES_ROLES",GET_INTERMEDIARY_STRUCTURES:"GET_INTERMEDIARY_STRUCTURES",SEARCH_INTERMEDIARIES:"SEARCH_INTERMEDIARIES",SEARCH_ACCOUNT_OFFICERS:"SEARCH_ACCOUNT_OFFICERS",GET_INTERMEDIARIES_STATES:"GET_INTERMEDIARIES_STATES",GET_INTERMEDIARIES_TYPES:"GET_INTERMEDIARIES_TYPES",CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY:"CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY",CREATE_INTERMEDIARY_WITH_WITH_PERSON:"CREATE_INTERMEDIARY_WITH_WITH_PERSON",CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION:"CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION",UPDATE_INTERMEDIARY:"UPDATE_INTERMEDIARY",CREATE_COMMERCIAL_STRUCTURE:"CREATE_COMMERCIAL_STRUCTURE",GET_COMMERCIAL_STRUCTURE_STATUSES:"GET_COMMERCIAL_STRUCTURE_STATUSES",SEARCH_COMMERCIAL_STRUCTURE:"SEARCH_COMMERCIAL_STRUCTURE",GET_COMMERCIAL_STRUCTURES_BY_CODE:"GET_COMMERCIAL_STRUCTURES_BY_CODE",UPDATE_COMMERCIAL_STRUCTURE:"UPDATE_COMMERCIAL_STRUCTURE",UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES:"UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES",GET_POLICY_SECTIONS:"GET_POLICY_SECTIONS",GET_POLICY_SUBSECTIONS:"GET_POLICY_SUBSECTIONS"},"GET_POLICY_PROCESSES","GET_POLICY_PROCESSES"),"GET_POLICY_PRODUCTS","GET_POLICY_PRODUCTS"),"GET_VALIDITY_TYPES","GET_VALIDITY_TYPES"),"GET_POLICY_CARACTERS","GET_POLICY_CARACTERS"),"GET_POLICY_TYPE_OF_DOCUMENTATION","GET_POLICY_TYPE_OF_DOCUMENTATION"),"GET_PAYMENT_FREQUENCIES","GET_PAYMENT_FREQUENCIES"),"GET_ASSOCIATE_TERMS_CONDITION","GET_ASSOCIATE_TERMS_CONDITION"),"GET_ASSOCIATE_EXPENSES","GET_ASSOCIATE_EXPENSES"),"GET_ASSOCIATE_COVERAGE","GET_ASSOCIATE_COVERAGE"),"GET_COVERAGES","GET_COVERAGES"),a(a(a(a(a(a(a(a(a(a(o,"GET_EXPENSEVALUES","GET_EXPENSEVALUES"),"GET_MORTALITY_TABLE","GET_MORTALITY_TABLE"),"CREATE_POLICY_STEP1","CREATE_POLICY_STEP1"),"CREATE_POLICY_STEP2","CREATE_POLICY_STEP2"),"CREATE_POLICY_STEP3","CREATE_POLICY_STEP3"),"CREATE_POLICY_STEP4","CREATE_POLICY_STEP4"),"CREATE_POLICY_STEP5","CREATE_POLICY_STEP5"),"CREATE_POLICY_STEP6","CREATE_POLICY_STEP6"),"CREATE_POLICY_STEP7","CREATE_POLICY_STEP7"),"CREATE_POLICY_STEP8","CREATE_POLICY_STEP8"),a(a(a(a(a(a(a(a(a(a(o,"CREATE_POLICY_STEP9","CREATE_POLICY_STEP9"),"CREATE_POLICY_STEP10","CREATE_POLICY_STEP10"),"CREATE_POLICY_STEP11","CREATE_POLICY_STEP11"),"GET_STEP1_DATA","GET_STEP1_DATA"),"GET_STEP2_DATA","GET_STEP2_DATA"),"GET_STEP3_DATA","GET_STEP3_DATA"),"GET_STEP4_DATA","GET_STEP4_DATA"),"GET_STEP5_DATA","GET_STEP5_DATA"),"GET_STEP6_DATA","GET_STEP6_DATA"),"GET_STEP7_DATA","GET_STEP7_DATA"),a(a(a(a(a(a(a(a(a(a(o,"GET_STEP9_DATA","GET_STEP9_DATA"),"GET_STEP11_DATA","GET_STEP11_DATA"),"GET_STEP11_FILE","GET_STEP11_FILE"),"UPDATE_POLICY_STEP1","UPDATE_POLICY_STEP1"),"GET_ISURED_PERSONS","GET_ISURED_PERSONS"),"UPDATE_PARTY","UPDATE_PARTY"),"GET_POLICY_DETAILS","GET_POLICY_DETAILS"),"UPDATE_PAYMENTS","UPDATE_PAYMENTS"),"CREATE_POLICY_RISK","CREATE_POLICY_RISK"),"ACTIVATE_POLICY","ACTIVATE_POLICY"),a(a(a(a(a(a(a(a(a(a(o,"COMPLETE_POLICY","COMPLETE_POLICY"),"SET_POLICY_BUILDING","SET_POLICY_BUILDING"),"SEARCH_POLICIES","SEARCH_POLICIES"),"SEARCH_POLICY_GENERAL_CONDITIONS","SEARCH_POLICY_GENERAL_CONDITIONS"),"GET_ASSURED_LIST","GET_ASSURED_LIST"),"GET_ADHERENTS","GET_ADHERENTS"),"GET_ADHERENTS_BY_OWNER","GET_ADHERENTS_BY_OWNER"),"GET_OWNERS","GET_OWNERS"),"GET_POLICY_ROLES","GET_POLICY_ROLES"),"CREATE_PRODUCT","CREATE_PRODUCT")),v=[{endpoint:E.SEARCH_INDIVIDUALS,serviceName:"individuals",url:"party/v1/individuals",method:d,module:u},{endpoint:E.CREATE_INDIVIDUAL,serviceName:"individuals",url:"party/v1/individuals",method:p,module:u},{endpoint:E.GET_ACTIVITIES,serviceName:"activities",url:"party/v1/activities/{0}",method:d,module:u},{endpoint:E.GET_PRACTICES,serviceName:"practices",url:"party/v1/practices/{0}",method:d,module:u},{endpoint:E.GET_SECTORS,serviceName:"sectors",url:"party/v1/sectors",method:d,module:u},{endpoint:E.GET_FISCAL_CATEGORIES,serviceName:"fiscal-categories",url:"party/v1/fiscal-categories?party-type-code={0}&country-code={1}",method:d,module:u},{endpoint:E.GET_MAIL_TYPES,serviceName:"mail-types",url:"party/v1/mail-types",method:d,module:u},{endpoint:E.GET_PHONE_TYPES,serviceName:"phone-types",url:"party/v1/phone-types",method:d,module:u},{endpoint:E.GET_IDENTIFICATION_TYPES,serviceName:"identification-types",url:"party/v1/identification-types?party-type-code={0}&country-code={1}",method:d,module:u},{endpoint:E.GET_RELATIONS,serviceName:"parties/relations",url:"party/v1/parties/{0}/relations",method:d,module:u},{endpoint:E.GET_NOTES,serviceName:"parties/notes",url:"party/v1/parties/{0}/notes",method:d,module:u},{endpoint:E.GET_FILES,serviceName:"parties/files",url:"party/v1/parties/{0}/files",method:d,module:u},{endpoint:E.UPDATE_NOTES,serviceName:"parties/notes",url:"party/v1/parties/{0}/notes",method:m,module:u},{endpoint:E.UPDATE_FILES,serviceName:"parties/files",url:"party/v1/parties/{0}/files",method:m,module:u},{endpoint:E.ADD_RELATION_WITH_EXISTING_PARTY,serviceName:"parties/relations",url:"party/v1/parties/{0}/relations",method:m,module:u},{endpoint:E.GET_RELATIONS_BY_PARTY_CODE,serviceName:"parties/relations",url:"party/v1/parties/{0}/relations",method:d,module:u},{endpoint:E.REMOVE_RELATION,serviceName:"parties/relations/disable",url:"party/v1/parties/{0}/relations/disable",method:m,module:u},{endpoint:E.GET_FILE,serviceName:"parties/file",url:"party/v1/parties/{0}/file/{1}",method:d,module:u},{endpoint:E.SEARCH_ORGANIZATION,serviceName:"organisations",url:"party/v1/organisations",method:d,module:u},{endpoint:E.GET_ORGANIZATION_TYPES,serviceName:"organisation-types",url:"party/v1/organisation-types",method:d,module:u},{endpoint:E.CREATE_ORGANIZATION,serviceName:"organisations",url:"party/v1/organisations",method:p,module:u},{endpoint:E.UPDATE_ORGANIZATION,serviceName:"organisations",url:"party/v1/organisations/{0}",method:m,module:u},{endpoint:E.GET_ORGANIZATION_BY_CODE,serviceName:"organisations",url:"party/v1/organisations/{0}",method:d,module:u},{endpoint:E.ADD_RELATION_WITH_NEW_ORGANIZATION,serviceName:"organisations/relations",url:"party/v1/organisations/{0}/relations",method:m,module:u},{endpoint:E.UPDATE_PERSON,serviceName:"individuals",url:"party/v1/individuals/{0}",method:m,module:u},{endpoint:E.SEARCH_PERSON,serviceName:"individuals",url:"party/v1/individuals",method:d,module:u},{endpoint:E.GET_PERSON_BY_CODE,serviceName:"individuals",url:"party/v1/individuals/{0}",method:d,module:u},{endpoint:E.GET_GENDERS,serviceName:"genders",url:"party/v1/genders",method:d,module:u},{endpoint:E.GET_MARITAL_STATUSES,serviceName:"marital-statuses",url:"party/v1/marital-statuses",method:d,module:u},{endpoint:E.GET_WORKER_TYPES,serviceName:"worker-types",url:"party/v1/worker-types",method:d,module:u},{endpoint:E.GET_ECONOMIC_CLASSES,serviceName:"economic-classes",url:"party/v1/economic-classes",method:d,module:u},{endpoint:E.GET_RELATION_TYPES,serviceName:"relation-types",url:"party/v1/relation-types/{0}",method:d,module:u},{endpoint:E.ADD_RELATION_WITH_NEW_PERSON,serviceName:"individuals/relations",url:"party/v1/individuals/{0}/relations",method:m,module:u},{endpoint:E.GET_POLICY_PROCESSES,serviceName:"policy-statuses",url:"policy/v1/policy-statuses",method:d,module:u},{endpoint:E.GET_COUNTRIES,serviceName:"countries",url:"location/v1/countries",method:d,module:u},{endpoint:E.GET_COUNTRY_BY_CODE,serviceName:"countries",url:"location/v1/countries/{0}",method:d,module:u},{endpoint:E.GET_PROVINCES,serviceName:"countries/provinces",url:"location/v1/countries/{0}/provinces",method:d,module:u},{endpoint:E.GET_CITIES,serviceName:"provinces/cities",url:"location/v1/provinces/{0}/cities",method:d,module:u},{endpoint:E.GET_POSTAL_CODES,serviceName:"cities/postal-codes",url:"location/v1/cities/{0}/postal-codes",method:d,module:u},{endpoint:E.GET_ADDRESSES_BY_PARTY_CODE,serviceName:"party/addresses",url:"location/v1/party/{0}/addresses",method:d,module:u},{endpoint:E.GET_ADDRESS_TYPES,serviceName:"address-types",url:"location/v1/address-types",method:d,module:u},{endpoint:E.GET_PAYMENT_METHODS_BY_PARTY_CODE,serviceName:"parties/payment-methods",url:"party/v1/parties/{0}/payment-methods",method:d,module:u},{endpoint:E.GET_CREDIT_CARD_TYPES,serviceName:"credit-card-types",url:"finance/v1/credit-card-types",method:d,module:u},{endpoint:E.GET_CARD_PROVIDERS,serviceName:"card-providers",url:"finance/v1/card-providers",method:d,module:u},{endpoint:E.UPDATE_PAYMENTS,serviceName:"parties/payment-methods",url:"party/v1/parties/{0}/payment-methods",method:m,module:u},{endpoint:E.GET_BANKS,serviceName:"banks",url:"finance/v1/banks",method:d,module:u},{endpoint:E.GET_CURRENCIES,serviceName:"currencies",url:"finance/v1/currencies",method:d,module:u},{endpoint:E.GET_BANK_ACCOUNT_TYPES,serviceName:"bank-account-types",url:"finance/v1/bank-account-types",method:d,module:u},{endpoint:E.GET_BANK_BRANCHES,serviceName:"banks/branches",url:"finance/v1/banks/{0}/branches",method:d,module:u},{endpoint:E.SEARCH_INTERMEDIARIES,serviceName:"intermediary",url:"intermediary/v1/intermediary",method:d,module:l},{endpoint:E.GET_PERSON_INTERMEDIARY_BY_CODE,serviceName:"intermediary-individual",url:"intermediary/v1/intermediary-individual/{0}",method:d,module:l},{endpoint:E.GET_ORGANIZATION_INTERMEDIARY_BY_CODE,serviceName:"intermediary-organisation",url:"intermediary/v1/intermediary-organisation/{0}",method:d,module:l},{endpoint:E.GET_INTERMEDIARIES_GROUPS,serviceName:"intermediary-groups",url:"intermediary/v1/intermediary-groups",method:d,module:l},{endpoint:E.GET_INTERMEDIARIES_ROLES,serviceName:"intermediary-roles",url:"intermediary/v1/intermediary-roles",method:d,module:l},{endpoint:E.GET_INTERMEDIARY_STRUCTURES,serviceName:"intermediary-structures",url:"intermediary/v1/intermediary/{0}/commercial-structures",method:d,module:l},{endpoint:E.GET_INTERMEDIARIES_STATES,serviceName:"commercial-structure-statuses",url:"intermediary/v1/commercial-structure-statuses",method:d,module:l},{endpoint:E.GET_INTERMEDIARIES_TYPES,serviceName:"intermediary-types",url:"intermediary/v1/intermediary-types",method:d,module:l},{endpoint:E.CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY,serviceName:"intermediary-party-association",url:"intermediary/v1/intermediary-party-association",method:p,module:l},{endpoint:E.CREATE_INTERMEDIARY_WITH_WITH_PERSON,serviceName:"intermediary-individual",url:"intermediary/v1/intermediary-individual",method:p,module:l},{endpoint:E.CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION,serviceName:"intermediary-organisation",url:"intermediary/v1/intermediary-organisation",method:p,module:l},{endpoint:E.UPDATE_INTERMEDIARY,serviceName:"intermediary",url:"intermediary/v1/intermediary/{0}",method:m,module:l},{endpoint:E.SEARCH_COMMERCIAL_STRUCTURE,serviceName:"commercial-structures",url:"intermediary/v1/commercial-structures",method:d,module:c},{endpoint:E.CREATE_COMMERCIAL_STRUCTURE,serviceName:"commercial-structures",url:"intermediary/v1/commercial-structures",method:p,module:c},{endpoint:E.GET_COMMERCIAL_STRUCTURE_STATUSES,serviceName:"commercial-structure-statuses",url:"intermediary/v1/commercial-structure-statuses",method:d,module:c},{endpoint:E.GET_COMMERCIAL_STRUCTURES_BY_CODE,serviceName:"commercial-structures",url:"intermediary/v1/commercial-structures/{0}",method:d,module:c},{endpoint:E.UPDATE_COMMERCIAL_STRUCTURE,serviceName:"commercial-structures",url:"intermediary/v1/commercial-structures/{0}",method:m,module:c},{endpoint:E.UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES,serviceName:"commercial-structures/intermediaries",url:"intermediary/v1/commercial-structures/{0}/intermediaries",method:m,module:c},{endpoint:E.SEARCH_POLICIES,serviceName:"policies",url:"policy/v1/policies",method:d,module:s},{endpoint:E.GET_POLICY_SECTIONS,serviceName:"sections",url:"product/v1/sections",method:d,module:s},{endpoint:E.GET_POLICY_SUBSECTIONS,serviceName:"sections/subsections",url:"product/v1/sections/{0}/subsections",method:d,module:s},{endpoint:E.GET_POLICY_PROCESSES,serviceName:"policy-statuses",url:"policy/v1/policy-statuses",method:d,module:s},{endpoint:E.GET_POLICY_PRODUCTS,serviceName:"subsections/products",url:"product/v1/subsections/{0}/products",method:d,module:s},{endpoint:E.GET_VALIDITY_TYPES,serviceName:"policy-validities",url:"policy/v1/policy-validities",method:d,module:s},{endpoint:E.GET_POLICY_CARACTERS,serviceName:"wording-types",url:"product/v1/wording-types",method:d,module:s},{endpoint:E.SEARCH_POLICY_GENERAL_CONDITIONS,serviceName:"wordings",url:"/product/v1/products/{0}/wordings",method:d,module:s},{endpoint:E.GET_POLICY_TYPE_OF_DOCUMENTATION,serviceName:"file-types",url:"policy/v1/file-types",method:d,module:s},{endpoint:E.GET_PAYMENT_FREQUENCIES,serviceName:"payment-frequencies",url:"policy/v1/payment-frequencies",method:d,module:s},{endpoint:E.GET_ASSOCIATE_TERMS_CONDITION,serviceName:"terms",url:"policy/v1/policies/{0}/terms",method:d,module:s},{endpoint:E.GET_ASSOCIATE_EXPENSES,serviceName:"expenses",url:"policy/v1/policies/{0}/expenses",method:d,module:s},{endpoint:E.GET_ASSOCIATE_COVERAGE,serviceName:"coverages",url:"policy-life/v1/policies/{0}/coverages",method:d,module:s},{endpoint:E.GET_COVERAGES,serviceName:"coverages",url:"product/v1/products/{0}/coverages",method:d,module:s},{endpoint:E.GET_EXPENSEVALUES,serviceName:"expenses",url:"/product/v1/products/{0}/expenses",method:d,module:s},{endpoint:E.GET_MORTALITY_TABLE,serviceName:"mortality-tables",url:"policy-life/v1/mortality-tables",method:d,module:s},{endpoint:E.CREATE_POLICY_STEP1,serviceName:"policies",url:"policy/v1/policies",method:p,module:s},{endpoint:E.CREATE_POLICY_STEP2,serviceName:"policies/roles",url:"policy/v1/policies/{0}/roles",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP3,serviceName:"policies/collections",url:"policy/v1/policies/{0}/collections",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP4,serviceName:"policies/commercial-structures",url:"policy/v1/policies/{0}/commercial-structures",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP5,serviceName:"policies/products",url:"policy-life/v1/policies/{0}/products",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP6,serviceName:"policies/coverages",url:"policy-life/v1/policies/{0}/coverages",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP7,serviceName:"policies/insurables",url:"policy-life/v1/policies/{0}/insurables",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP8,serviceName:"policies/expenses",url:"policy/v1/policies/{0}/expenses",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP9,serviceName:"policies/wordings",url:"policy/v1/policies/{0}/wordings",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP10,serviceName:"policies/terms",url:"policy/v1/policies/{0}/terms",method:m,module:s},{endpoint:E.CREATE_POLICY_STEP11,serviceName:"policies/documentation",url:"policy/v1/policies/{0}/documentation",method:m,module:s},{endpoint:E.GET_STEP1_DATA,serviceName:"policies",url:"policy/v1/policies/{0}",method:d,module:s},{endpoint:E.GET_STEP2_DATA,serviceName:"policies/roles",url:"policy/v1/policies/{0}/roles",method:d,module:s},{endpoint:E.GET_STEP3_DATA,serviceName:"policies/collections",url:"policy/v1/policies/{0}/collections",method:d,module:s},{endpoint:E.GET_STEP4_DATA,serviceName:"policies/commercial-structures",url:"policy/v1/policies/{0}/commercial-structures",method:d,module:s},{endpoint:E.GET_STEP5_DATA,serviceName:"policies/products",url:"policy/v1/policies/{0}/products",method:d,module:s},{endpoint:E.GET_STEP6_DATA,serviceName:"policies/coverages",url:"policy-life/v1/policies/{0}/coverages",method:d,module:s},{endpoint:E.GET_STEP7_DATA,serviceName:"policies/insurables",url:"policy-life/v1/policies/{0}/insurables",method:d,module:s},{endpoint:E.GET_STEP9_DATA,serviceName:"policies/wordings",url:"policy/v1/policies/{0}/wordings",method:d,module:s},{endpoint:E.GET_STEP11_DATA,serviceName:"policies/documentation",url:"policy/v1/policies/{0}/documentation",method:d,module:s},{endpoint:E.GET_STEP11_FILE,serviceName:"policies/file",url:"policy/v1/policies/{0}/file/{1}",method:d,module:s},{endpoint:E.UPDATE_POLICY_STEP1,serviceName:"policies",url:"policy/v1/policies/{0}",method:m,module:s},{endpoint:E.GET_ISURED_PERSONS,serviceName:"insurables",url:"policy-life/v1/products/{0}/insurables",method:d,module:s},{endpoint:E.UPDATE_PARTY,serviceName:"parties",url:"policy/v1/parties/{0}",method:m,module:s},{endpoint:E.GET_POLICY_DETAILS,serviceName:"policies/details",url:"policy-life/v1/policies/{0}/details",method:d,module:s},{endpoint:E.UPDATE_PAYMENTS,serviceName:"policies/collections",url:"policy/v1/policies/collections",method:m,module:s},{endpoint:E.CREATE_POLICY_RISK,serviceName:"policies",url:"policy-life/v1/policies/{0}/insureds",method:p,module:s},{endpoint:E.ACTIVATE_POLICY,serviceName:"policies/activate",url:"policy-life/v1/policies/{0}/activate",method:m,module:s},{endpoint:E.COMPLETE_POLICY,serviceName:"policies/complete",url:"/policy-life/v1/policies/{0}/complete",method:m,module:s},{endpoint:E.SET_POLICY_BUILDING,serviceName:"policies/build",url:"policy-life/v1/policies/{0}/build",method:m,module:s},{endpoint:E.GET_POLICY_ROLES,serviceName:"policies/roles",url:"policy/v1/policies/{0}/roles",method:d,module:s},{endpoint:E.GET_ASSURED_LIST,serviceName:"insureds",url:"policy-life/v1/policies/{0}/insureds",method:d,module:s},{endpoint:E.GET_ADHERENTS,serviceName:"adherents",url:"policy-life/v1/adherents/{0}",method:d,module:s},{endpoint:E.GET_OWNERS,serviceName:"owners",url:"policy-life/v1/owners/{0}",method:d,module:s},{endpoint:E.GET_ADHERENTS_BY_OWNER,serviceName:"owners/adherents",url:"policy-life/v1/owners/{0}/adherents",method:d,module:s},{endpoint:E.SEARCH_ACCOUNT_OFFICERS,serviceName:"account-officers",url:"intermediary/v1/account-officers",method:d,module:l},{endpoint:E.CREATE_PRODUCT,serviceName:"configurator-product-creation",url:"policy-life/v1/products",method:p,module:"CONFIGURATOR_MODULE"}];function f(e){return f="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},f(e)}function h(){h=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var i=t&&t.prototype instanceof T?t:T,a=Object.create(i.prototype),u=new b(n||[]);return o(a,"_invoke",{value:C(e,r,u)}),a}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var p="suspendedStart",m="suspendedYield",E="executing",v="completed",y={};function T(){}function _(){}function A(){}var N={};c(N,a,(function(){return this}));var S=Object.getPrototypeOf,I=S&&S(S(G([])));I&&I!==r&&n.call(I,a)&&(N=I);var O=A.prototype=T.prototype=Object.create(N);function g(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function R(e,t){function r(o,i,a,u){var l=d(e[o],e,i);if("throw"!==l.type){var c=l.arg,s=c.value;return s&&"object"==f(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(s).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(l.arg)}var i;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return i=i?i.then(o,o):o()}})}function C(t,r,n){var o=p;return function(i,a){if(o===E)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var l=P(u,n);if(l){if(l===y)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=E;var c=d(t,r,n);if("normal"===c.type){if(o=n.done?v:m,c.arg===y)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function P(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,P(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),y;var i=d(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,y;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,y):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,y)}function D(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function b(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(D,this),this.reset(!0)}function G(t){if(t||""===t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(f(t)+" is not iterable")}return _.prototype=A,o(O,"constructor",{value:A,configurable:!0}),o(A,"constructor",{value:_,configurable:!0}),_.displayName=c(A,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===_||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,A):(e.__proto__=A,c(e,l,"GeneratorFunction")),e.prototype=Object.create(O),e},t.awrap=function(e){return{__await:e}},g(R.prototype),c(R.prototype,u,(function(){return this})),t.AsyncIterator=R,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new R(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},g(O),c(O,l,"Generator"),c(O,a,(function(){return this})),c(O,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=G,b.prototype={constructor:b,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(l&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,y):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),y},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),L(r),y}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;L(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:G(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),y}},t}function y(e,t,r,n,o,i,a){try{var u=e[i](a),l=u.value}catch(e){return void r(e)}u.done?t(l):Promise.resolve(l).then(n,o)}var T=function(e,t){try{var n={title:"",errors:[]};if(t instanceof r.AxiosError){var o,i,a=t.response,u=a.status,l=null===(o=JSON.parse(localStorage.getItem("modules_info")).find((function(t){return t.code===e.module})))||void 0===o||null===(o=o.services)||void 0===o||null===(o=o.find((function(t){return t.name.toUpperCase()===e.serviceName.toUpperCase()&&t.httpMethod.toUpperCase()===e.method.toUpperCase()})))||void 0===o?void 0:o.errors.find((function(e){return e.httpStatus===u}));n.title=(null==l?void 0:l.content)||a.data.message;var c=null===(i=a.data.errorMessages)||void 0===i?void 0:i.map((function(e){var t,r=null==l||null===(t=l.subErrors)||void 0===t?void 0:t.find((function(t){return t.errorType===e.fieldError&&t.fieldName===e.fieldName}));return(null==r?void 0:r.content)||(null==e?void 0:e.error)}));n.errors=c||[]}else n.title=t.message}catch(t){throw console.error(t),t}},_=function(e,t){return t?e.replace(/{(\d+)}/g,(function(e,r){return t[r]?t[r]:e})):e},A=function(){var e,t=(e=h().mark((function e(t,r){var o,i,a,u,l=arguments;return h().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(o=l.length>2&&void 0!==l[2]?l[2]:null,i=v.find((function(e){return e.endpoint===t})),e.prev=2,i){e.next=5;break}throw new Error("Service does not exists");case 5:a=_(i.url,r),e.t0=i.method,e.next=e.t0===d?9:e.t0===p?13:e.t0===m?17:"DELETE"===e.t0?21:25;break;case 9:return e.next=11,n.get(a,{params:o});case 11:case 15:case 19:case 23:return u=e.sent,e.abrupt("return",u.data);case 13:return e.next=15,n.post(a,o);case 17:return e.next=19,n.put(a,o);case 21:return e.next=23,n.delete(a,o);case 25:throw u=null,new Error("Request error: Method not allowed. Only use GET, POST, PUT, DELETE");case 27:e.next=33;break;case 29:throw e.prev=29,e.t1=e.catch(2),T(i,e.t1),e.t1;case 33:case"end":return e.stop()}}),e,null,[[2,29]])})),function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){y(i,n,o,a,u,"next",e)}function u(e){y(i,n,o,a,u,"throw",e)}a(void 0)}))});return function(e,r){return t.apply(this,arguments)}}();function N(e){return N="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},N(e)}function S(){S=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var i=t&&t.prototype instanceof h?t:h,a=Object.create(i.prototype),u=new b(n||[]);return o(a,"_invoke",{value:C(e,r,u)}),a}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var p="suspendedStart",m="suspendedYield",E="executing",v="completed",f={};function h(){}function y(){}function T(){}var _={};c(_,a,(function(){return this}));var A=Object.getPrototypeOf,I=A&&A(A(G([])));I&&I!==r&&n.call(I,a)&&(_=I);var O=T.prototype=h.prototype=Object.create(_);function g(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function R(e,t){function r(o,i,a,u){var l=d(e[o],e,i);if("throw"!==l.type){var c=l.arg,s=c.value;return s&&"object"==N(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(s).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(l.arg)}var i;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return i=i?i.then(o,o):o()}})}function C(t,r,n){var o=p;return function(i,a){if(o===E)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var l=P(u,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=E;var c=d(t,r,n);if("normal"===c.type){if(o=n.done?v:m,c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function P(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,P(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var i=d(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,f;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,f):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,f)}function D(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function b(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(D,this),this.reset(!0)}function G(t){if(t||""===t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(N(t)+" is not iterable")}return y.prototype=T,o(O,"constructor",{value:T,configurable:!0}),o(T,"constructor",{value:y,configurable:!0}),y.displayName=c(T,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,T):(e.__proto__=T,c(e,l,"GeneratorFunction")),e.prototype=Object.create(O),e},t.awrap=function(e){return{__await:e}},g(R.prototype),c(R.prototype,u,(function(){return this})),t.AsyncIterator=R,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new R(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},g(O),c(O,l,"Generator"),c(O,a,(function(){return this})),c(O,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=G,b.prototype={constructor:b,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(l&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),L(r),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;L(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:G(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),f}},t}function I(e,t,r,n,o,i,a){try{var u=e[i](a),l=u.value}catch(e){return void r(e)}u.done?t(l):Promise.resolve(l).then(n,o)}var O=function(){var e,t=(e=S().mark((function e(t){var r,n;return S().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return n={values:null==t||null===(r=t.claims)||void 0===r?void 0:r.map((function(e){return{claimNumber:e.claimNumber.toString(),policyNumber:e.policyNumber,creationDate:e.claimDate,status:{name:e.status,code:"N/A"}}}))},e.abrupt("return",n);case 2:case"end":return e.stop()}}),e)})),function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){I(i,n,o,a,u,"next",e)}function u(e){I(i,n,o,a,u,"throw",e)}a(void 0)}))});return function(e){return t.apply(this,arguments)}}();const g=require("moment");var R=e.n(g);function C(e){return C="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},C(e)}function P(){P=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var i=t&&t.prototype instanceof h?t:h,a=Object.create(i.prototype),u=new b(n||[]);return o(a,"_invoke",{value:g(e,r,u)}),a}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var p="suspendedStart",m="suspendedYield",E="executing",v="completed",f={};function h(){}function y(){}function T(){}var _={};c(_,a,(function(){return this}));var A=Object.getPrototypeOf,N=A&&A(A(G([])));N&&N!==r&&n.call(N,a)&&(_=N);var S=T.prototype=h.prototype=Object.create(_);function I(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function O(e,t){function r(o,i,a,u){var l=d(e[o],e,i);if("throw"!==l.type){var c=l.arg,s=c.value;return s&&"object"==C(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(s).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(l.arg)}var i;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return i=i?i.then(o,o):o()}})}function g(t,r,n){var o=p;return function(i,a){if(o===E)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var l=R(u,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=E;var c=d(t,r,n);if("normal"===c.type){if(o=n.done?v:m,c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function R(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,R(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var i=d(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,f;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,f):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,f)}function D(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function L(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function b(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(D,this),this.reset(!0)}function G(t){if(t||""===t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(C(t)+" is not iterable")}return y.prototype=T,o(S,"constructor",{value:T,configurable:!0}),o(T,"constructor",{value:y,configurable:!0}),y.displayName=c(T,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,T):(e.__proto__=T,c(e,l,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},I(O.prototype),c(O.prototype,u,(function(){return this})),t.AsyncIterator=O,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new O(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},I(S),c(S,l,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=G,b.prototype={constructor:b,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(L),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(l&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),L(r),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;L(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:G(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),f}},t}function D(e,t,r,n,o,i,a){try{var u=e[i](a),l=u.value}catch(e){return void r(e)}u.done?t(l):Promise.resolve(l).then(n,o)}function L(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){D(i,n,o,a,u,"next",e)}function u(e){D(i,n,o,a,u,"throw",e)}a(void 0)}))}}var b=function(){var e=L(P().mark((function e(t){var r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={total:t.insureds.length,totalActive:null,values:t.insureds.map((function(e){return{code:e.code,number:e.id,firstName:e.firstName||e.name,lastName:e.lastName,type:{code:"T"===e.role.code?"OWNER":"ADHERENT",name:"T"===e.role.code?"Titular":"Adherente"},status:{code:"ACTIVE",name:"Activo"},insuredAmount:e.insuredAmount,inclusionDate:e.entranceDate,exclusionDate:e.cancellationDate,identification:{value:e.identification.number,type:{name:e.identification.type.name,code:e.identification.type.code}}}}))},e.abrupt("return",r);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),G=function(){var e=L(P().mark((function e(t){var r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={values:t.endorsements.map((function(e){return{number:e.number,validityFrom:e.dateFrom?R()(e.dateFrom,"DD/MM/YYYY").toISOString():null,validityTo:e.dateTo?R()(e.dateTo,"DD/MM/YYYY").toISOString():null,activeDate:"N/A",type:{code:"N/A",name:e.detail,group:{code:"N/A",name:"N/A"}}}})),total:t.endorsements.length},e.abrupt("return",r);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),w=function(){var e=L(P().mark((function e(t){var r;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={values:t.policies.map((function(e){var t,r,n,o,i,a,u,l,c,s;return{number:e.number,validityFrom:e.issueDate?R()(e.issueDate,"DD/MM/YYYY").toISOString():null,validityTo:"N/A",ingress:e.issueDate?R()(e.issueDate,"DD/MM/YYYY").toISOString():null,holder:{name:(null===(t=e.holder)||void 0===t?void 0:t.name)||(null===(r=e.holder)||void 0===r?void 0:r.firstName),identifications:{values:[{value:(null===(n=e.holder)||void 0===n||null===(n=n.identification)||void 0===n?void 0:n.number)||null,type:{name:(null===(o=e.holder)||void 0===o||null===(o=o.identification)||void 0===o||null===(o=o.type)||void 0===o?void 0:o.name)||null,code:(null===(i=e.holder)||void 0===i||null===(i=i.identification)||void 0===i||null===(i=i.type)||void 0===i?void 0:i.code)||null},default:!0}]}},code:"N/A",alias:"N/A",product:{code:(null===(a=e.section)||void 0===a?void 0:a.code.toString())||null,name:(null===(u=e.section)||void 0===u?void 0:u.name)||null,subsection:{name:"N/A",code:"N/A",section:{name:(null===(l=e.section)||void 0===l?void 0:l.name)||null,code:(null===(c=e.section)||void 0===c?void 0:c.code)||null}}},process:{name:(null===(s=e.status)||void 0===s?void 0:s.name)||null,code:"N/A"}}})),total:t.totalRecord||null},e.abrupt("return",r);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),Y=function(){var e=L(P().mark((function e(t){var r,n,o,i,a,u,l,c,s,d,p,m,E,v,f,h,y,T,_,A,N,S,I,O,g,C,D,L,b,G,w,Y;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return Y={policyData:{number:(null==t?void 0:t.number)||null,alias:"N/A",currency:{name:(null==t||null===(r=t.currency)||void 0===r?void 0:r.name)||null,code:(null==t||null===(n=t.currency)||void 0===n?void 0:n.code)||null,mnemonic:"N/A",symbol:(null==t||null===(o=t.currency)||void 0===o?void 0:o.symbol)||null},validity:{type:{name:(null==t||null===(i=t.currency)||void 0===i?void 0:i.name)||null,code:(null==t||null===(a=t.currency)||void 0===a?void 0:a.code)||null,months:"N/A"},dateFrom:null!=t&&t.vigencyDateFrom?R()(t.vigencyDateFrom,"YYYY/MM/DD").toISOString():null,dateTo:null!=t&&t.vigencyDateTo?R()(t.vigencyDateTo,"YYYY/MM/DD").toISOString():null},creationDate:null!=t&&t.issueDate?R()(t.issueDate,"YYYY/MM/DD").toISOString():null,renewable:!0,process:{name:(null==t||null===(u=t.status)||void 0===u?void 0:u.name)||null,code:"N/A"}},roleData:{holder:{partyCode:(null==t||null===(l=t.holder)||void 0===l?void 0:l.code)||null,name:null!=t&&null!==(c=t.holder)&&void 0!==c&&c.firstName&&null!=t&&null!==(s=t.holder)&&void 0!==s&&s.lastName?"".concat(t.holder.firstName," ").concat(t.holder.lastName):(null==t||null===(d=t.holder)||void 0===d?void 0:d.name)||null,identification:{value:(null==t||null===(p=t.holder)||void 0===p||null===(p=p.identification)||void 0===p?void 0:p.number)||null,type:{code:(null==t||null===(m=t.holder)||void 0===m||null===(m=m.identification)||void 0===m||null===(m=m.type)||void 0===m?void 0:m.code)||null,name:(null==t||null===(E=t.holder)||void 0===E||null===(E=E.identification)||void 0===E||null===(E=E.type)||void 0===E?void 0:E.name)||null}}},contacts:[{partyCode:"N/A",name:"N/A",identification:{value:"N/A",type:{name:"N/A",code:"N/A"}}}],legalResponsible:{partyCode:"N/A",name:"N/A",identification:{value:"N/A",type:{name:"N/A",code:"N/A"}}}},collectionData:{holderDistribution:0,insuredDistribution:0,paymentFrequency:{name:(null==t||null===(v=t.paymentMethod)||void 0===v||null===(v=v.periodicity)||void 0===v?void 0:v.name)||null,code:"N/A"},paymentMethodData:{cashMethodData:"CASH"===(null==t||null===(f=t.paymentMethod)||void 0===f?void 0:f.name)?{values:[{code:"N/A",name:(null==t||null===(h=t.currency)||void 0===h?void 0:h.name)||null}]}:null,bankAccountData:"CBU"===(null==t||null===(y=t.paymentMethod)||void 0===y?void 0:y.name)?{values:[{code:"BA-1",number:"1",cbu:(null==t||null===(T=t.paymentMethod)||void 0===T?void 0:T.bankAccountNumber)||null,alias:"N/A",currency:{code:"N/A",name:(null==t||null===(_=t.currency)||void 0===_?void 0:_.name)||null},bankBranch:{name:"N/A",code:"N/A",bank:{name:"N/A",code:"N/A"}},bankAccountType:{name:"N/A",code:"N/A"}}]}:null,creditCardData:"CREDIT"===(null==t||null===(A=t.paymentMethod)||void 0===A?void 0:A.name)?{values:[{code:"N/A",ownerName:"N/A",cardType:{name:"N/A",code:"N/A"},cardProvider:{name:"N/A",code:"N/A"},number:"N/A",securityCode:"N/A",dateTo:"N/A"}]}:null}},commercialStructureData:{data:{name:"N/A",code:"N/A",version:0,description:"N/A",status:{name:"N/A",code:"N/A"}},intermediaries:{values:[{code:(null==t||null===(N=t.intermediary)||void 0===N||null===(N=N.code)||void 0===N?void 0:N.toString())||null,name:(null==t||null===(S=t.intermediary)||void 0===S?void 0:S.name)||null,licence:"N/A",role:{name:"N/A",code:"N/A"},status:{name:"N/A",code:"N/A"}}]}},productData:{name:(null==t||null===(I=t.product)||void 0===I?void 0:I.name)||null,code:(null==t||null===(O=t.product)||void 0===O?void 0:O.code)||null,version:0,subsection:{name:"N/A",code:"N/A",section:{name:(null==t||null===(g=t.section)||void 0===g?void 0:g.name)||null,code:(null==t||null===(C=t.section)||void 0===C?void 0:C.code)||null}},status:{name:(null==t||null===(D=t.status)||void 0===D?void 0:D.name)||null,code:"N/A"}},coverageData:{coverages:(null==t||null===(L=t.insured)||void 0===L||null===(L=L.coverages)||void 0===L?void 0:L.map((function(e){return{coverage:{name:(null==e?void 0:e.name)||null,code:"N/A",calculatorType:{name:"N/A",code:"N/A"},type:{name:"N/A",code:"N/A"}},values:[{type:{name:"N/A",code:"N/A"},maxValue:"N/A",minValue:"N/A"}],mortalityTable:{name:"N/A",code:"N/A"},ageType:{name:"N/A",code:"N/A"}}})))||[]},expenseData:{values:[]},wordingData:{wordings:[]},termData:{values:[]},documentationData:{files:[],comments:"N/A"},endorsementData:{number:(null==t?void 0:t.endorsementNumber)||0,validityFrom:"N/A",validityTo:"N/A",type:{name:"N/A",code:"N/A"}},insurableData:{minimumQuantityInsured:0,estimatedDeadline:(null==t||null===(b=t.insured)||void 0===b?void 0:b.entranceDate)||null,minimumAge:0,maximumAge:0,maximumQuantityInsuredByEvent:0,maximumAmountToIndemnify:"N/A",insurables:null!=t&&t.insured?[{type:{name:(null==t||null===(G=t.insured)||void 0===G||null===(G=G.type)||void 0===G?void 0:G.name)||null,code:(null==t||null===(w=t.insured)||void 0===w||null===(w=w.type)||void 0===w?void 0:w.code)||null},wording:"N/A",minimumEntryAge:0,maximumEntryAge:0,endingAgePrincipalCoverage:0,endingAgeAditionalCoverage:0}]:null}},e.abrupt("return",Y);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),M=function(){var e=L(P().mark((function e(t){var r,n,o,i,a,u,l,c,s,d,p,m,E,v,f,h,y,T,_,A,N,S,I,O,g,C,D,L,b,G,w,Y;return P().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return Y={policyData:{number:(null==t?void 0:t.number)||null,alias:"N/A",currency:{name:(null==t||null===(r=t.currency)||void 0===r?void 0:r.name)||null,code:(null==t||null===(n=t.currency)||void 0===n?void 0:n.code)||null,mnemonic:"N/A",symbol:(null==t||null===(o=t.currency)||void 0===o?void 0:o.symbol)||null},validity:{type:{name:(null==t||null===(i=t.currency)||void 0===i?void 0:i.name)||null,code:(null==t||null===(a=t.currency)||void 0===a?void 0:a.code)||null,months:"N/A"},dateFrom:null!=t&&t.vigencyDateFrom?R()(t.vigencyDateFrom,"YYYY/MM/DD").toISOString():null,dateTo:null!=t&&t.vigencyDateTo?R()(t.vigencyDateTo,"YYYY/MM/DD").toISOString():null},creationDate:null!=t&&t.issueDate?R()(t.issueDate,"YYYY/MM/DD").toISOString():null,renewable:!0,process:{name:(null==t||null===(u=t.status)||void 0===u?void 0:u.name)||null,code:"N/A"}},roleData:{holder:{partyCode:(null==t||null===(l=t.holder)||void 0===l?void 0:l.code)||null,name:null!=t&&null!==(c=t.holder)&&void 0!==c&&c.firstName&&null!=t&&null!==(s=t.holder)&&void 0!==s&&s.lastName?"".concat(t.holder.firstName," ").concat(t.holder.lastName):(null==t||null===(d=t.holder)||void 0===d?void 0:d.name)||null,identification:{value:(null==t||null===(p=t.holder)||void 0===p||null===(p=p.identification)||void 0===p?void 0:p.number)||null,type:{code:(null==t||null===(m=t.holder)||void 0===m||null===(m=m.identification)||void 0===m||null===(m=m.type)||void 0===m?void 0:m.code)||null,name:(null==t||null===(E=t.holder)||void 0===E||null===(E=E.identification)||void 0===E||null===(E=E.type)||void 0===E?void 0:E.name)||null}}},contacts:[{partyCode:"N/A",name:"N/A",identification:{value:"N/A",type:{name:"N/A",code:"N/A"}}}],legalResponsible:{partyCode:"N/A",name:"N/A",identification:{value:"N/A",type:{name:"N/A",code:"N/A"}}}},collectionData:{holderDistribution:0,insuredDistribution:0,paymentFrequency:{name:(null==t||null===(v=t.paymentMethod)||void 0===v||null===(v=v.periodicity)||void 0===v?void 0:v.name)||null,code:"N/A"},paymentMethodData:{cashMethodData:"CASH"===(null==t||null===(f=t.paymentMethod)||void 0===f?void 0:f.name)?{values:[{code:"N/A",name:(null==t||null===(h=t.currency)||void 0===h?void 0:h.name)||null}]}:null,bankAccountData:"CBU"===(null==t||null===(y=t.paymentMethod)||void 0===y?void 0:y.name)?{values:[{code:"BA-1",number:"1",cbu:(null==t||null===(T=t.paymentMethod)||void 0===T?void 0:T.bankAccountNumber)||null,alias:"N/A",currency:{code:"N/A",name:(null==t||null===(_=t.currency)||void 0===_?void 0:_.name)||null},bankBranch:{name:"N/A",code:"N/A",bank:{name:"N/A",code:"N/A"}},bankAccountType:{name:"N/A",code:"N/A"}}]}:null,creditCardData:"CREDIT"===(null==t||null===(A=t.paymentMethod)||void 0===A?void 0:A.name)?{values:[{code:"N/A",ownerName:"N/A",cardType:{name:"N/A",code:"N/A"},cardProvider:{name:"N/A",code:"N/A"},number:"N/A",securityCode:"N/A",dateTo:"N/A"}]}:null}},commercialStructureData:{data:{name:"N/A",code:"N/A",version:0,description:"N/A",status:{name:"N/A",code:"N/A"}},intermediaries:{values:[{code:(null==t||null===(N=t.intermediary)||void 0===N||null===(N=N.code)||void 0===N?void 0:N.toString())||null,name:(null==t||null===(S=t.intermediary)||void 0===S?void 0:S.name)||null,licence:"N/A",role:{name:"N/A",code:"N/A"},status:{name:"N/A",code:"N/A"}}]}},productData:{name:(null==t||null===(I=t.product)||void 0===I?void 0:I.name)||null,code:(null==t||null===(O=t.product)||void 0===O?void 0:O.code)||null,version:0,subsection:{name:"N/A",code:"N/A",section:{name:(null==t||null===(g=t.section)||void 0===g?void 0:g.name)||null,code:(null==t||null===(C=t.section)||void 0===C?void 0:C.code)||null}},status:{name:(null==t||null===(D=t.status)||void 0===D?void 0:D.name)||null,code:"N/A"}},coverageData:{coverages:(null==t||null===(L=t.insured)||void 0===L||null===(L=L.coverages)||void 0===L?void 0:L.map((function(e){return{coverage:{name:(null==e?void 0:e.name)||null,code:"N/A",calculatorType:{name:"N/A",code:"N/A"},type:{name:"N/A",code:"N/A"}},values:[{type:{name:"N/A",code:"N/A"},maxValue:"N/A",minValue:"N/A"}],mortalityTable:{name:"N/A",code:"N/A"},ageType:{name:"N/A",code:"N/A"}}})))||[]},expenseData:{values:[]},wordingData:{wordings:[]},termData:{values:[]},documentationData:{files:[],comments:"N/A"},endorsementData:{number:(null==t?void 0:t.endorsementNumber)||0,validityFrom:"N/A",validityTo:"N/A",type:{name:"N/A",code:"N/A"}},insurableData:{minimumQuantityInsured:0,estimatedDeadline:(null==t||null===(b=t.insured)||void 0===b?void 0:b.entranceDate)||null,minimumAge:0,maximumAge:0,maximumQuantityInsuredByEvent:0,maximumAmountToIndemnify:"N/A",insurables:null!=t&&t.insured?[{type:{name:(null==t||null===(G=t.insured)||void 0===G||null===(G=G.type)||void 0===G?void 0:G.name)||null,code:(null==t||null===(w=t.insured)||void 0===w||null===(w=w.type)||void 0===w?void 0:w.code)||null},wording:"N/A",minimumEntryAge:0,maximumEntryAge:0,endingAgePrincipalCoverage:0,endingAgeAditionalCoverage:0}]:null}},e.abrupt("return",Y);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),x=function(e){return{ANNUAL:6,MONTHLY:1,QUARTERLY:3,SEMI_ANNUAL:5}[e]||6},U=function(e){return{SC_SC:534,VI_VI_VIDA_IND_1:120,OTRO_CODIGO:0}[e]||404};function j(e){return j="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},j(e)}function q(){q=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var i=t&&t.prototype instanceof h?t:h,a=Object.create(i.prototype),u=new D(n||[]);return o(a,"_invoke",{value:g(e,r,u)}),a}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var p="suspendedStart",m="suspendedYield",E="executing",v="completed",f={};function h(){}function y(){}function T(){}var _={};c(_,a,(function(){return this}));var A=Object.getPrototypeOf,N=A&&A(A(L([])));N&&N!==r&&n.call(N,a)&&(_=N);var S=T.prototype=h.prototype=Object.create(_);function I(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function O(e,t){function r(o,i,a,u){var l=d(e[o],e,i);if("throw"!==l.type){var c=l.arg,s=c.value;return s&&"object"==j(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(s).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(l.arg)}var i;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return i=i?i.then(o,o):o()}})}function g(t,r,n){var o=p;return function(i,a){if(o===E)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var l=R(u,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=E;var c=d(t,r,n);if("normal"===c.type){if(o=n.done?v:m,c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function R(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,R(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var i=d(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,f;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,f):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,f)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function D(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function L(t){if(t||""===t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(j(t)+" is not iterable")}return y.prototype=T,o(S,"constructor",{value:T,configurable:!0}),o(T,"constructor",{value:y,configurable:!0}),y.displayName=c(T,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,T):(e.__proto__=T,c(e,l,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},I(O.prototype),c(O.prototype,u,(function(){return this})),t.AsyncIterator=O,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new O(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},I(S),c(S,l,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=L,D.prototype={constructor:D,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(l&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),P(r),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:L(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),f}},t}function k(e,t,r,n,o,i,a){try{var u=e[i](a),l=u.value}catch(e){return void r(e)}u.done?t(l):Promise.resolve(l).then(n,o)}function F(e){return function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){k(i,n,o,a,u,"next",e)}function u(e){k(i,n,o,a,u,"throw",e)}a(void 0)}))}}var B=function(){var e=F(q().mark((function e(t){var r;return q().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={quotations:t.quotations.map((function(e){var t,r;return{code:"N/A",creationDate:"N/A",email:"N/A",expirationDate:"N/A",number:e.quotationNumber||null,paymentFrequency:{name:"N/A",code:"N/A"},product:{code:(null===(t=e.productCode)||void 0===t?void 0:t.toString())||null,name:"N/A",subsection:{code:"N/A",name:"N/A",section:{code:(null===(r=e.sectionCode)||void 0===r?void 0:r.toString())||null,name:"N/A"}},version:0},status:{code:"N/A",name:"N/A"}}})),total:"N/A"},e.abrupt("return",r);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),H=function(){var e=F(q().mark((function e(t){var r,n,o,i;return q().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return i={code:(null===(r=t.quotationNumber)||void 0===r?void 0:r.toString())||null,number:t.activityCode||0,creationDate:t.vigencyDateFrom||null,expirationDate:t.vigencyDateTo||null,validity:{code:"N/A",name:"N/A",months:"N/A"},status:{code:"N/A",name:"N/A"},paymentFrequency:{name:"N/A",code:"N/A",months:0},email:"N/A",phone:"N/A",intermediary:{code:"N/A",name:"N/A",roles:{}},commercialStructure:{data:{name:"N/A",code:"N/A",version:0,description:"N/A",status:{name:"N/A",code:"N/A"}},intermediaries:{values:[{code:"N/A",name:"N/A",licence:"N/A",role:{name:"N/A",code:"N/A"},status:{name:"N/A",code:"N/A"},group:{name:"N/A",code:"N/A"}}]}},product:{name:"N/A",code:(null==t||null===(n=t.productCode)||void 0===n?void 0:n.toString())||null,version:0,subsection:{name:"N/A",code:"N/A",section:{name:"N/A",code:(null==t||null===(o=t.sectionCode)||void 0===o?void 0:o.toString())||null,type:{name:"N/A",code:"N/A"},category:{name:"N/A",code:"N/A"}}},status:{code:"N/A",name:"N/A"},currency:{name:"N/A",code:"N/A",mnemonic:"N/A",symbol:"N/A"}},productSegment:{coverages:[],expenses:[],name:"N/A",code:"N/A",version:0,description:"N/A"},values:{risks:[{code:"N/A",coverages:[{code:"N/A",name:"N/A",deductible:{name:"N/A",code:"N/A",value:0,appliedValue:0},economicValues:[{type:{name:"N/A",code:"N/A"},value:0}],coverageValues:[{type:{name:"N/A",code:"N/A"},value:0}]}],data:{},adherents:[{code:"N/A",coverages:[{code:"N/A",name:"N/A",deductible:{name:"N/A",code:"N/A",value:0,appliedValue:0},economicValues:[{type:"N/A",code:"N/A"}],coverageValues:[{type:{name:"N/A",code:"N/A"},value:0}]}],data:{}}]}],expenses:[{type:{name:"N/A",code:"N/A"},value:0}],groupedEconomicValues:[{type:{name:"N/A",code:"N/A"},value:0}],commercialAgreement:{}}},e.abrupt("return",i);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),V=function(e){return e?{sectionCode:17,paymentTypeCode:x(e.paymentFrequencyCode),productCode:U(e.productCode),provinceCode:1}:null},W=function(e){var t,r;return e?{sectionCode:17,paymentTypeCode:x(e.paymentFrequencyCode),productCode:U(e.productCode),provinceCode:1,birthdate:null===(t=e.risks[0])||void 0===t?void 0:t.birthDate,insuredAmount:(null===(r=e.risks[0])||void 0===r||null===(r=r.coverages[0])||void 0===r||null===(r=r.values.find((function(e){return"INSURED_AMOUNT"===e.code})))||void 0===r?void 0:r.value)||0}:null},Z=function(){var e=F(q().mark((function e(t){var r;return q().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:return r={values:t.activities.map((function(e){return{code:e.code,name:e.name}}))},e.abrupt("return",r);case 2:case"end":return e.stop()}}),e)})));return function(t){return e.apply(this,arguments)}}(),K="GET",Q="POST",X={GET_ACTIVITY:{default:{url:"party/v1/sectors",method:K,source:"https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1sectors/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"quotation/v1/activity",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=get-v1-activity",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return Z(e)}}},GET_CLAIMS:{default:{url:"claim/v1/claims",method:K,source:"https://apidoc.sysone.com/claim/v1/open-api.html",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"claim/v1/claim",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=claim-api&operation=get-v1-claim-pagenumber-pagenumber-pagesize-pagesize",requestMapper:null,responseMapper:function(e){return O(e)}}},GET_ENDORSEMENTS:{default:{url:"policy/v1/policies/{0}/endorsements",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1endorsements/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy/{0}/{1}/endorsements",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-policy-number-section-code-endorsements",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return G(e)}}},GET_INSUREDS:{default:{url:"policy-life/v1/policies/{0}/insureds",method:K,source:"https://apidoc.sysone.com/policy-life/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1insureds/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy/{0}/{1}/policy-insured",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-policy-number-section-code-insureds",requestMapper:function(e){return{mappedParams:(t=e,{code:t.number||void 0,name:t.firstName||void 0})};var t},responseMapper:function(e){return b(e)}}},GET_POLICIES:{default:{url:"policy/v1/policies",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-pagenumber-pagenumber-sort-sort-ordertype-ordertype-pagesize-p",requestMapper:function(e){return{mappedParams:(t=e,{sort:"TomadorCodigo",orderType:"desc",pageNumber:t.page||1,pageSize:t.pageSize||10,allPolicies:null})};var t},responseMapper:function(e){return w(e)}}},GET_POLICY_HOME_COLLECTIVE_DETAIL:{default:{url:"policy-home/v1/policies/{0}/details",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy-individual/{0}/{1}/detail",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return M(e)}}},GET_POLICY_HOME_INDIVIDUAL_DETAIL:{default:{url:"policy-home/v1/policies/{0}/details",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy-individual/{0}/{1}/detail",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return Y(e)}}},GET_POLICY_LIFE_COLLECTIVE_DETAIL:{default:{url:"policy-life/v1/policies/{0}/details",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy-individual/{0}/{1}/detail",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return M(e)}}},GET_POLICY_LIFE_INDIVIDUAL_DETAIL:{default:{url:"policy-life/v1/policies/{0}/details",method:K,source:"https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"policy/v1/policy-individual/{0}/{1}/detail",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return Y(e)}}},GET_QUOTATION_BY_CODE:{default:{url:"quotation/v1/quotations/{0}",method:K,source:"https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations~1%7Bcode%7D/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"quotation/v1/quotation/standard-plan/{0}",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=get-v1-quotation-standard-plan-number",requestMapper:function(e){return{mappedParams:{}}},responseMapper:function(e){return H(e)}}},GET_QUOTATIONS:{default:{url:"quotation/v1/quotations",method:K,source:"https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/get",requestMapper:function(e){return{mappedParams:e}},responseMapper:function(e){return e}},cnp:{url:"quotation/v1/quotation/variable-plan",method:K,source:"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=get-v1-quotation-variable-plan",requestMapper:function(e){return{mappedParams:(t=e,{number:t.quotationNumber})};var t},responseMapper:function(e){return B(e)}}},GET_PAYMENT_METHODS:{},POST_INSURED_UPDATE:{default:{url:"policy-life/v1/policies/{0}/insureds",method:Q,requestMapper:null,source:"https://apidoc.sysone.com/policy-life/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1insureds/post",responseMapper:function(e){return e}},cnp:{url:"v1/policy-collective/{0}/{1}/insureds",method:Q,requestMapper:null,source:"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=post-v1-policy-collective-policy-number-section-code-insureds",responseMapper:function(e){return{salary:"string"==typeof(t=e).salary?t.salary:String(t.salary),identification:"string"==typeof t.identification?t.identification:String(t.identification)};var t}}},POST_CREATE_QUOTATION_STANDARD_PLAN:{default:{url:"quotation/v1/quotations",method:Q,source:"https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/post",requestMapper:function(e){return{mappedBody:e}},responseMapper:function(e){return e}},cnp:{url:"quotation/v1/quotation/standard-plan",method:Q,source:"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=post-v1-quotation-standard-plan",requestMapper:function(e){return{mappedBody:V(e)}},responseMapper:function(e){return e}}},POST_CREATE_QUOTATION_VARIABLE_PLAN:{default:{url:"quotation/v1/quotations",method:Q,source:"https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/post",requestMapper:function(e){return{mappedBody:e}},responseMapper:function(e){return e}},cnp:{url:"quotation/v1/quotation/variable-plan",method:Q,source:"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=post-v1-quotation-variable-plan",requestMapper:function(e){return{mappedBody:W(e)}},responseMapper:function(e){return e}}},CREATE_INSURED:{}};const z=require("dotenv");function J(e){return J="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},J(e)}function $(){$=function(){return t};var e,t={},r=Object.prototype,n=r.hasOwnProperty,o=Object.defineProperty||function(e,t,r){e[t]=r.value},i="function"==typeof Symbol?Symbol:{},a=i.iterator||"@@iterator",u=i.asyncIterator||"@@asyncIterator",l=i.toStringTag||"@@toStringTag";function c(e,t,r){return Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}),e[t]}try{c({},"")}catch(e){c=function(e,t,r){return e[t]=r}}function s(e,t,r,n){var i=t&&t.prototype instanceof h?t:h,a=Object.create(i.prototype),u=new D(n||[]);return o(a,"_invoke",{value:g(e,r,u)}),a}function d(e,t,r){try{return{type:"normal",arg:e.call(t,r)}}catch(e){return{type:"throw",arg:e}}}t.wrap=s;var p="suspendedStart",m="suspendedYield",E="executing",v="completed",f={};function h(){}function y(){}function T(){}var _={};c(_,a,(function(){return this}));var A=Object.getPrototypeOf,N=A&&A(A(L([])));N&&N!==r&&n.call(N,a)&&(_=N);var S=T.prototype=h.prototype=Object.create(_);function I(e){["next","throw","return"].forEach((function(t){c(e,t,(function(e){return this._invoke(t,e)}))}))}function O(e,t){function r(o,i,a,u){var l=d(e[o],e,i);if("throw"!==l.type){var c=l.arg,s=c.value;return s&&"object"==J(s)&&n.call(s,"__await")?t.resolve(s.__await).then((function(e){r("next",e,a,u)}),(function(e){r("throw",e,a,u)})):t.resolve(s).then((function(e){c.value=e,a(c)}),(function(e){return r("throw",e,a,u)}))}u(l.arg)}var i;o(this,"_invoke",{value:function(e,n){function o(){return new t((function(t,o){r(e,n,t,o)}))}return i=i?i.then(o,o):o()}})}function g(t,r,n){var o=p;return function(i,a){if(o===E)throw Error("Generator is already running");if(o===v){if("throw"===i)throw a;return{value:e,done:!0}}for(n.method=i,n.arg=a;;){var u=n.delegate;if(u){var l=R(u,n);if(l){if(l===f)continue;return l}}if("next"===n.method)n.sent=n._sent=n.arg;else if("throw"===n.method){if(o===p)throw o=v,n.arg;n.dispatchException(n.arg)}else"return"===n.method&&n.abrupt("return",n.arg);o=E;var c=d(t,r,n);if("normal"===c.type){if(o=n.done?v:m,c.arg===f)continue;return{value:c.arg,done:n.done}}"throw"===c.type&&(o=v,n.method="throw",n.arg=c.arg)}}}function R(t,r){var n=r.method,o=t.iterator[n];if(o===e)return r.delegate=null,"throw"===n&&t.iterator.return&&(r.method="return",r.arg=e,R(t,r),"throw"===r.method)||"return"!==n&&(r.method="throw",r.arg=new TypeError("The iterator does not provide a '"+n+"' method")),f;var i=d(o,t.iterator,r.arg);if("throw"===i.type)return r.method="throw",r.arg=i.arg,r.delegate=null,f;var a=i.arg;return a?a.done?(r[t.resultName]=a.value,r.next=t.nextLoc,"return"!==r.method&&(r.method="next",r.arg=e),r.delegate=null,f):a:(r.method="throw",r.arg=new TypeError("iterator result is not an object"),r.delegate=null,f)}function C(e){var t={tryLoc:e[0]};1 in e&&(t.catchLoc=e[1]),2 in e&&(t.finallyLoc=e[2],t.afterLoc=e[3]),this.tryEntries.push(t)}function P(e){var t=e.completion||{};t.type="normal",delete t.arg,e.completion=t}function D(e){this.tryEntries=[{tryLoc:"root"}],e.forEach(C,this),this.reset(!0)}function L(t){if(t||""===t){var r=t[a];if(r)return r.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var o=-1,i=function r(){for(;++o<t.length;)if(n.call(t,o))return r.value=t[o],r.done=!1,r;return r.value=e,r.done=!0,r};return i.next=i}}throw new TypeError(J(t)+" is not iterable")}return y.prototype=T,o(S,"constructor",{value:T,configurable:!0}),o(T,"constructor",{value:y,configurable:!0}),y.displayName=c(T,l,"GeneratorFunction"),t.isGeneratorFunction=function(e){var t="function"==typeof e&&e.constructor;return!!t&&(t===y||"GeneratorFunction"===(t.displayName||t.name))},t.mark=function(e){return Object.setPrototypeOf?Object.setPrototypeOf(e,T):(e.__proto__=T,c(e,l,"GeneratorFunction")),e.prototype=Object.create(S),e},t.awrap=function(e){return{__await:e}},I(O.prototype),c(O.prototype,u,(function(){return this})),t.AsyncIterator=O,t.async=function(e,r,n,o,i){void 0===i&&(i=Promise);var a=new O(s(e,r,n,o),i);return t.isGeneratorFunction(r)?a:a.next().then((function(e){return e.done?e.value:a.next()}))},I(S),c(S,l,"Generator"),c(S,a,(function(){return this})),c(S,"toString",(function(){return"[object Generator]"})),t.keys=function(e){var t=Object(e),r=[];for(var n in t)r.push(n);return r.reverse(),function e(){for(;r.length;){var n=r.pop();if(n in t)return e.value=n,e.done=!1,e}return e.done=!0,e}},t.values=L,D.prototype={constructor:D,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=e,this.done=!1,this.delegate=null,this.method="next",this.arg=e,this.tryEntries.forEach(P),!t)for(var r in this)"t"===r.charAt(0)&&n.call(this,r)&&!isNaN(+r.slice(1))&&(this[r]=e)},stop:function(){this.done=!0;var e=this.tryEntries[0].completion;if("throw"===e.type)throw e.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var r=this;function o(n,o){return u.type="throw",u.arg=t,r.next=n,o&&(r.method="next",r.arg=e),!!o}for(var i=this.tryEntries.length-1;i>=0;--i){var a=this.tryEntries[i],u=a.completion;if("root"===a.tryLoc)return o("end");if(a.tryLoc<=this.prev){var l=n.call(a,"catchLoc"),c=n.call(a,"finallyLoc");if(l&&c){if(this.prev<a.catchLoc)return o(a.catchLoc,!0);if(this.prev<a.finallyLoc)return o(a.finallyLoc)}else if(l){if(this.prev<a.catchLoc)return o(a.catchLoc,!0)}else{if(!c)throw Error("try statement without catch or finally");if(this.prev<a.finallyLoc)return o(a.finallyLoc)}}}},abrupt:function(e,t){for(var r=this.tryEntries.length-1;r>=0;--r){var o=this.tryEntries[r];if(o.tryLoc<=this.prev&&n.call(o,"finallyLoc")&&this.prev<o.finallyLoc){var i=o;break}}i&&("break"===e||"continue"===e)&&i.tryLoc<=t&&t<=i.finallyLoc&&(i=null);var a=i?i.completion:{};return a.type=e,a.arg=t,i?(this.method="next",this.next=i.finallyLoc,f):this.complete(a)},complete:function(e,t){if("throw"===e.type)throw e.arg;return"break"===e.type||"continue"===e.type?this.next=e.arg:"return"===e.type?(this.rval=this.arg=e.arg,this.method="return",this.next="end"):"normal"===e.type&&t&&(this.next=t),f},finish:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.finallyLoc===e)return this.complete(r.completion,r.afterLoc),P(r),f}},catch:function(e){for(var t=this.tryEntries.length-1;t>=0;--t){var r=this.tryEntries[t];if(r.tryLoc===e){var n=r.completion;if("throw"===n.type){var o=n.arg;P(r)}return o}}throw Error("illegal catch attempt")},delegateYield:function(t,r,n){return this.delegate={iterator:L(t),resultName:r,nextLoc:n},"next"===this.method&&(this.arg=e),f}},t}function ee(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(e);t&&(n=n.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),r.push.apply(r,n)}return r}function te(e){for(var t=1;t<arguments.length;t++){var r=null!=arguments[t]?arguments[t]:{};t%2?ee(Object(r),!0).forEach((function(t){re(e,t,r[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):ee(Object(r)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(r,t))}))}return e}function re(e,t,r){return(t=function(e){var t=function(e){if("object"!=J(e)||!e)return e;var t=e[Symbol.toPrimitive];if(void 0!==t){var r=t.call(e,"string");if("object"!=J(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"==J(t)?t:t+""}(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function ne(e,t,r,n,o,i,a){try{var u=e[i](a),l=u.value}catch(e){return void r(e)}u.done?t(l):Promise.resolve(l).then(n,o)}e.n(z)().config();var oe=JSON.parse("'{")["api-mapper"],ie=function(){var e,t=(e=$().mark((function e(t,r,o){var i,a,u,l,c,s,d,p,m,E,v,f,h=arguments;return $().wrap((function(e){for(;;)switch(e.prev=e.next){case 0:if(i=h.length>3&&void 0!==h[3]?h[3]:null,e.prev=1,u=X[t]){e.next=5;break}throw new Error("Endpoint no configurado: ".concat(t));case 5:if(l=null!==(a=u[r])&&void 0!==a?a:u.default,oe){e.next=8;break}throw new Error("No se pudo cargar la configuración del API Mapper");case 8:c="cnp"===r?oe.cnp:te(te({},oe.default),{},{headers:te(te({},oe.default.headers),{},re(re({},"X-Tenant",r),"X-User",r))}),c=te(te({},c),{},{validateStatus:function(e){return e<500}}),s=ae(l.url,o),e.t0=l.method,e.next=e.t0===K?14:e.t0===Q?20:"PUT"===e.t0?26:"DELETE"===e.t0?30:34;break;case 14:return p=l.requestMapper(i),m=p.mappedParams,e.next=18,n.get(s,te(te({},c),{},{params:m}));case 18:case 24:case 28:case 32:return d=e.sent,e.abrupt("return",l.responseMapper(d.data));case 20:return p=l.requestMapper(i),v=(E=p).mappedPostParams,f=E.mappedBody,e.next=24,n.post(s,f,te(te({},c),{},{params:v}));case 26:return e.next=28,n.put(s,i);case 30:return e.next=32,n.delete(s,i);case 34:throw d=null,new Error("Request error: Method not allowed. Only use GET, POST, PUT, DELETE");case 36:e.next=41;break;case 38:throw e.prev=38,e.t1=e.catch(1),e.t1;case 41:case"end":return e.stop()}}),e,null,[[1,38]])})),function(){var t=this,r=arguments;return new Promise((function(n,o){var i=e.apply(t,r);function a(e){ne(i,n,o,a,u,"next",e)}function u(e){ne(i,n,o,a,u,"throw",e)}a(void 0)}))});return function(e,r,n){return t.apply(this,arguments)}}(),ae=function(e,t){return t?e.replace(/{(\d+)}/g,(function(e,r){return t[r]?t[r]:e})):e};module.exports=t})();
1
+ /*
2
+ * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
3
+ * This devtool is neither made for production nor for readable output files.
4
+ * It uses "eval()" calls to create a separate source file in the browser devtools.
5
+ * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
6
+ * or disable the default devtool with "devtool: false".
7
+ * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
8
+ */
9
+ /******/ (() => { // webpackBootstrap
10
+ /******/ "use strict";
11
+ /******/ var __webpack_modules__ = ({
12
+
13
+ /***/ "./axiosInstance.js":
14
+ /*!**************************!*\
15
+ !*** ./axiosInstance.js ***!
16
+ \**************************/
17
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
18
+
19
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ \"default\": () => (__WEBPACK_DEFAULT_EXPORT__)\n/* harmony export */ });\n/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! axios */ \"axios\");\n/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(axios__WEBPACK_IMPORTED_MODULE_0__);\n\nvar axiosInstance = axios__WEBPACK_IMPORTED_MODULE_0___default().create({\n baseURL: ''\n});\n/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (axiosInstance);\n\n//# sourceURL=webpack://sysone-api-mapper/./axiosInstance.js?");
20
+
21
+ /***/ }),
22
+
23
+ /***/ "./index.js":
24
+ /*!******************!*\
25
+ !*** ./index.js ***!
26
+ \******************/
27
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
28
+
29
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ apiCall: () => (/* reexport safe */ _services__WEBPACK_IMPORTED_MODULE_0__.apiCall),\n/* harmony export */ apiMapper: () => (/* reexport safe */ _src_mapper_Mapper__WEBPACK_IMPORTED_MODULE_3__.apiMapper),\n/* harmony export */ axiosInstance: () => (/* reexport safe */ _axiosInstance__WEBPACK_IMPORTED_MODULE_2__[\"default\"]),\n/* harmony export */ configureApiMapper: () => (/* reexport safe */ _src_mapper_Mapper__WEBPACK_IMPORTED_MODULE_3__.configureApiMapper),\n/* harmony export */ endpoints: () => (/* reexport safe */ _servicesData__WEBPACK_IMPORTED_MODULE_1__.endpoints)\n/* harmony export */ });\n/* harmony import */ var _services__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./services */ \"./services.js\");\n/* harmony import */ var _servicesData__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./servicesData */ \"./servicesData.js\");\n/* harmony import */ var _axiosInstance__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./axiosInstance */ \"./axiosInstance.js\");\n/* harmony import */ var _src_mapper_Mapper__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./src/mapper/Mapper */ \"./src/mapper/Mapper.js\");\n\n\n\n\n\n\n//# sourceURL=webpack://sysone-api-mapper/./index.js?");
30
+
31
+ /***/ }),
32
+
33
+ /***/ "./services.js":
34
+ /*!*********************!*\
35
+ !*** ./services.js ***!
36
+ \*********************/
37
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
38
+
39
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ apiCall: () => (/* binding */ apiCall),\n/* harmony export */ formatNumberES: () => (/* binding */ formatNumberES)\n/* harmony export */ });\n/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! axios */ \"axios\");\n/* harmony import */ var axios__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(axios__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var _axiosInstance__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./axiosInstance */ \"./axiosInstance.js\");\n/* harmony import */ var _servicesData__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./servicesData */ \"./servicesData.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\n\n\n// import {\n// \topenNotificationWithIcon,\n// \tTYPE,\n// } from \"./src/components/notificationToast\";\n\nvar handleApiError = function handleApiError(service, e) {\n try {\n var errorToDisplay = {\n title: \"\",\n errors: []\n };\n if (!(e instanceof axios__WEBPACK_IMPORTED_MODULE_0__.AxiosError)) {\n errorToDisplay.title = e.message;\n } else {\n var _modulesInfo$find, _error$data$errorMess;\n var error = e.response;\n var statusError = error.status;\n var modulesInfo = JSON.parse(localStorage.getItem(\"modules_info\"));\n var translationInfo = (_modulesInfo$find = modulesInfo.find(function (m) {\n return m.code === service.module;\n })) === null || _modulesInfo$find === void 0 || (_modulesInfo$find = _modulesInfo$find.services) === null || _modulesInfo$find === void 0 || (_modulesInfo$find = _modulesInfo$find.find(function (s) {\n return s.name.toUpperCase() === service.serviceName.toUpperCase() && s.httpMethod.toUpperCase() === service.method.toUpperCase();\n })) === null || _modulesInfo$find === void 0 ? void 0 : _modulesInfo$find.errors.find(function (e) {\n return e.httpStatus === statusError;\n });\n errorToDisplay.title = (translationInfo === null || translationInfo === void 0 ? void 0 : translationInfo.content) || error.data.message;\n var subErrorTranslations = (_error$data$errorMess = error.data.errorMessages) === null || _error$data$errorMess === void 0 ? void 0 : _error$data$errorMess.map(function (err) {\n var _translationInfo$subE;\n var translatedSubError = translationInfo === null || translationInfo === void 0 || (_translationInfo$subE = translationInfo.subErrors) === null || _translationInfo$subE === void 0 ? void 0 : _translationInfo$subE.find(function (s) {\n return s.errorType === err.fieldError && s.fieldName === err.fieldName;\n });\n return (translatedSubError === null || translatedSubError === void 0 ? void 0 : translatedSubError.content) || (err === null || err === void 0 ? void 0 : err.error);\n });\n errorToDisplay.errors = subErrorTranslations || [];\n }\n\n // openNotificationWithIcon(\n // \tTYPE.ERROR,\n // \t\"\",\n // \terrorToDisplay.title,\n // \terrorToDisplay.errors\n // );\n } catch (e) {\n console.error(e);\n throw e;\n }\n};\nvar getUrl = function getUrl(serviceUrl, routeParams) {\n if (!routeParams) return serviceUrl;\n return serviceUrl.replace(/{(\\d+)}/g, function (match, routeParamNumber) {\n return routeParams[routeParamNumber] ? routeParams[routeParamNumber] : match;\n });\n};\nvar formatNumberES = function formatNumberES(n) {\n var _parseFloat;\n var d = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;\n n = new Intl.NumberFormat(\"de-DE\").format((_parseFloat = parseFloat(n)) === null || _parseFloat === void 0 ? void 0 : _parseFloat.toFixed(d));\n if (d > 0) {\n var decimals = n.indexOf(\",\") > -1 ? n.length - 1 - n.indexOf(\",\") : 0;\n n = decimals == 0 ? n + \",\" + \"0\".repeat(d) : n + \"0\".repeat(d - decimals);\n }\n return n;\n};\nvar apiCall = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(endpoint, routeParams) {\n var params,\n service,\n url,\n response,\n _args = arguments;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n params = _args.length > 2 && _args[2] !== undefined ? _args[2] : null;\n service = _servicesData__WEBPACK_IMPORTED_MODULE_2__.services.find(function (s) {\n return s.endpoint === endpoint;\n });\n _context.prev = 2;\n if (service) {\n _context.next = 5;\n break;\n }\n throw new Error(\"Service does not exists\");\n case 5:\n url = getUrl(service.url, routeParams);\n _context.t0 = service.method;\n _context.next = _context.t0 === _servicesData__WEBPACK_IMPORTED_MODULE_2__.methods.GET ? 9 : _context.t0 === _servicesData__WEBPACK_IMPORTED_MODULE_2__.methods.POST ? 13 : _context.t0 === _servicesData__WEBPACK_IMPORTED_MODULE_2__.methods.PUT ? 17 : _context.t0 === _servicesData__WEBPACK_IMPORTED_MODULE_2__.methods.DELETE ? 21 : 25;\n break;\n case 9:\n _context.next = 11;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_1__[\"default\"].get(url, {\n params: params\n });\n case 11:\n response = _context.sent;\n return _context.abrupt(\"return\", response.data);\n case 13:\n _context.next = 15;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_1__[\"default\"].post(url, params);\n case 15:\n response = _context.sent;\n return _context.abrupt(\"return\", response.data);\n case 17:\n _context.next = 19;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_1__[\"default\"].put(url, params);\n case 19:\n response = _context.sent;\n return _context.abrupt(\"return\", response.data);\n case 21:\n _context.next = 23;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_1__[\"default\"][\"delete\"](url, params);\n case 23:\n response = _context.sent;\n return _context.abrupt(\"return\", response.data);\n case 25:\n response = null;\n throw new Error(\"Request error: Method not allowed. Only use GET, POST, PUT, DELETE\");\n case 27:\n _context.next = 33;\n break;\n case 29:\n _context.prev = 29;\n _context.t1 = _context[\"catch\"](2);\n handleApiError(service, _context.t1);\n throw _context.t1;\n case 33:\n case \"end\":\n return _context.stop();\n }\n }, _callee, null, [[2, 29]]);\n }));\n return function apiCall(_x, _x2) {\n return _ref.apply(this, arguments);\n };\n}();\n\n//# sourceURL=webpack://sysone-api-mapper/./services.js?");
40
+
41
+ /***/ }),
42
+
43
+ /***/ "./servicesData.js":
44
+ /*!*************************!*\
45
+ !*** ./servicesData.js ***!
46
+ \*************************/
47
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
48
+
49
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ endpoints: () => (/* binding */ endpoints),\n/* harmony export */ methods: () => (/* binding */ methods),\n/* harmony export */ modules: () => (/* binding */ modules),\n/* harmony export */ services: () => (/* binding */ services)\n/* harmony export */ });\nvar _endpoints;\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nvar modules = {\n PARTY: \"PARTY_MODULE\",\n INTERMEDIARY: \"INTERMEDIARY_MODULE\",\n COMMERCIAL_STRUCTURE: \"COMMERCIAL_STRUCTURE_MODULE\",\n POLICY: \"POLICY_MODULE\",\n BILLING: \"BILLING_MODULE\",\n COLLECTION: \"COLLECTION_MODULE\",\n ACCOUNTING: \"ACCOUNTING_MODULE\",\n CONFIGURATOR: \"CONFIGURATOR_MODULE\"\n //falta agregar los endpoints para billing, collection, accounting, configurator\n};\nvar methods = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n DELETE: \"DELETE\"\n};\nvar endpoints = (_endpoints = {\n // *************** PARTY_MODULE ****************\n // ------PEOPLE-------\n GET_ACTIVITIES: \"GET_ACTIVITIES\",\n GET_PRACTICES: \"GET_PRACTICES\",\n SEARCH_INDIVIDUALS: \"SEARCH_INDIVIDUALS\",\n CREATE_INDIVIDUAL: \"CREATE_INDIVIDUAL\",\n GET_IDENTIFICATION_TYPES: \"GET_IDENTIFICATION_TYPES\",\n GET_RELATIONS: \"GET_RELATIONS\",\n GET_NOTES: \"GET_NOTES\",\n GET_FILES: \"GET_FILES\",\n GET_SECTORS: \"GET_SECTORS\",\n GET_FISCAL_CATEGORIES: \"GET_FISCAL_CATEGORIES\",\n GET_MAIL_TYPES: \"GET_MAIL_TYPES\",\n GET_PHONE_TYPES: \"GET_PHONE_TYPES\",\n UPDATE_NOTES: \"UPDATE_NOTES\",\n UPDATE_FILES: \"UPDATE_FILES\",\n ADD_RELATION_WITH_EXISTING_PARTY: \"ADD_RELATION_WITH_EXISTING_PARTY\",\n GET_RELATIONS_BY_PARTY_CODE: \"GET_RELATIONS_BY_PARTY_CODE\",\n REMOVE_RELATION: \"REMOVE_RELATION\",\n GET_FILE: \"GET_FILE\",\n //-ORGANIZATION-ENDPOINTS\n GET_ORGANIZATION_TYPES: \"GET_ORGANIZATION_TYPES\",\n SEARCH_ORGANIZATION: \"SEARCH_ORGANIZATION\",\n CREATE_ORGANIZATION: \"CREATE_ORGANIZATION\",\n GET_ORGANIZATION_BY_CODE: \"GET_ORGANIZATION_BY_CODE\",\n UPDATE_ORGANIZATION: \"UPDATE_ORGANIZATION\",\n ADD_RELATION_WITH_NEW_ORGANIZATION: \"ADD_RELATION_WITH_NEW_ORGANIZATION\",\n //-PEOPLE-ENDPOINTS\n GET_PERSON_BY_CODE: \"GET_PERSON_BY_CODE\",\n GET_GENDERS: \"GET_GENDERS\",\n GET_MARITAL_STATUSES: \"GET_MARITAL_STATUSES\",\n GET_WORKER_TYPES: \"GET_WORKER_TYPES\",\n GET_ECONOMIC_CLASSES: \"GET_ECONOMIC_CLASSES\",\n SEARCH_PERSON: \"SEARCH_PERSON\",\n UPDATE_PERSON: \"UPDATE_PERSON\",\n GET_RELATION_TYPES: \"GET_RELATION_TYPES\",\n ADD_RELATION_WITH_NEW_PERSON: \"ADD_RELATION_WITH_NEW_PERSON\",\n // ------POLICIES-------\n GET_POLICY_PROCESSES: \"GET_POLICY_PROCESSES\",\n // ------LOCATION-------\n GET_COUNTRIES: \"GET_COUNTRIES\",\n GET_COUNTRY_BY_CODE: \"GET_COUNTRY_BY_CODE\",\n GET_PROVINCES: \"GET_PROVINCES\",\n GET_CITIES: \"GET_CITIES\",\n GET_POSTAL_CODES: \"GET_POSTAL_CODES\",\n GET_ADDRESSES_BY_PARTY_CODE: \"GET_ADDRESSES_BY_PARTY_CODE\",\n GET_ADDRESS_TYPES: \"GET_ADDRESS_TYPES\",\n // ------FINANCE-------\n GET_PAYMENT_METHODS_BY_PARTY_CODE: \"GET_PAYMENT_METHODS_BY_PARTY_CODE\",\n GET_CREDIT_CARD_TYPES: \"GET_CREDIT_CARD_TYPES\",\n GET_CARD_PROVIDERS: \"GET_CARD_PROVIDERS\",\n UPDATE_PAYMENTS: \"UPDATE_PAYMENTS\",\n GET_BANKS: \"GET_BANKS\",\n GET_CURRENCIES: \"GET_CURRENCIES\",\n GET_BANK_ACCOUNT_TYPES: \"GET_BANK_ACCOUNT_TYPES\",\n GET_BANK_BRANCHES: \"GET_BANK_BRANCHES\",\n // **************** INTERMEDIARY_MODULE ****************\n // ------INTERMEDIARIES-------\n GET_PERSON_INTERMEDIARY_BY_CODE: \"GET_PERSON_INTERMEDIARY_BY_CODE\",\n GET_ORGANIZATION_INTERMEDIARY_BY_CODE: \"GET_ORGANIZATION_INTERMEDIARY_BY_CODE\",\n GET_INTERMEDIARIES_GROUPS: \"GET_INTERMEDIARIES_GROUPS\",\n GET_INTERMEDIARIES_ROLES: \"GET_INTERMEDIARIES_ROLES\",\n GET_INTERMEDIARY_STRUCTURES: \"GET_INTERMEDIARY_STRUCTURES\",\n SEARCH_INTERMEDIARIES: \"SEARCH_INTERMEDIARIES\",\n SEARCH_ACCOUNT_OFFICERS: \"SEARCH_ACCOUNT_OFFICERS\",\n GET_INTERMEDIARIES_STATES: \"GET_INTERMEDIARIES_STATES\",\n GET_INTERMEDIARIES_TYPES: \"GET_INTERMEDIARIES_TYPES\",\n CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY: \"CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY\",\n CREATE_INTERMEDIARY_WITH_WITH_PERSON: \"CREATE_INTERMEDIARY_WITH_WITH_PERSON\",\n CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION: \"CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION\",\n UPDATE_INTERMEDIARY: \"UPDATE_INTERMEDIARY\",\n // **************** COMMERCIAL_STRUCTURE_MODULE ****************\n // ------COMMERCIAL-STRUCTURES-------\n CREATE_COMMERCIAL_STRUCTURE: \"CREATE_COMMERCIAL_STRUCTURE\",\n GET_COMMERCIAL_STRUCTURE_STATUSES: \"GET_COMMERCIAL_STRUCTURE_STATUSES\",\n SEARCH_COMMERCIAL_STRUCTURE: \"SEARCH_COMMERCIAL_STRUCTURE\",\n GET_COMMERCIAL_STRUCTURES_BY_CODE: \"GET_COMMERCIAL_STRUCTURES_BY_CODE\",\n UPDATE_COMMERCIAL_STRUCTURE: \"UPDATE_COMMERCIAL_STRUCTURE\",\n UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES: \"UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES\",\n // ********************** POLICY_MODULE **********************\n // ------POLICIES-------\n GET_POLICY_SECTIONS: \"GET_POLICY_SECTIONS\",\n GET_POLICY_SUBSECTIONS: \"GET_POLICY_SUBSECTIONS\"\n}, _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_endpoints, \"GET_POLICY_PROCESSES\", \"GET_POLICY_PROCESSES\"), \"GET_POLICY_PRODUCTS\", \"GET_POLICY_PRODUCTS\"), \"GET_VALIDITY_TYPES\", \"GET_VALIDITY_TYPES\"), \"GET_POLICY_CARACTERS\", \"GET_POLICY_CARACTERS\"), \"GET_POLICY_TYPE_OF_DOCUMENTATION\", \"GET_POLICY_TYPE_OF_DOCUMENTATION\"), \"GET_PAYMENT_FREQUENCIES\", \"GET_PAYMENT_FREQUENCIES\"), \"GET_ASSOCIATE_TERMS_CONDITION\", \"GET_ASSOCIATE_TERMS_CONDITION\"), \"GET_ASSOCIATE_EXPENSES\", \"GET_ASSOCIATE_EXPENSES\"), \"GET_ASSOCIATE_COVERAGE\", \"GET_ASSOCIATE_COVERAGE\"), \"GET_COVERAGES\", \"GET_COVERAGES\"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_endpoints, \"GET_EXPENSEVALUES\", \"GET_EXPENSEVALUES\"), \"GET_MORTALITY_TABLE\", \"GET_MORTALITY_TABLE\"), \"CREATE_POLICY_STEP1\", \"CREATE_POLICY_STEP1\"), \"CREATE_POLICY_STEP2\", \"CREATE_POLICY_STEP2\"), \"CREATE_POLICY_STEP3\", \"CREATE_POLICY_STEP3\"), \"CREATE_POLICY_STEP4\", \"CREATE_POLICY_STEP4\"), \"CREATE_POLICY_STEP5\", \"CREATE_POLICY_STEP5\"), \"CREATE_POLICY_STEP6\", \"CREATE_POLICY_STEP6\"), \"CREATE_POLICY_STEP7\", \"CREATE_POLICY_STEP7\"), \"CREATE_POLICY_STEP8\", \"CREATE_POLICY_STEP8\"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_endpoints, \"CREATE_POLICY_STEP9\", \"CREATE_POLICY_STEP9\"), \"CREATE_POLICY_STEP10\", \"CREATE_POLICY_STEP10\"), \"CREATE_POLICY_STEP11\", \"CREATE_POLICY_STEP11\"), \"GET_STEP1_DATA\", \"GET_STEP1_DATA\"), \"GET_STEP2_DATA\", \"GET_STEP2_DATA\"), \"GET_STEP3_DATA\", \"GET_STEP3_DATA\"), \"GET_STEP4_DATA\", \"GET_STEP4_DATA\"), \"GET_STEP5_DATA\", \"GET_STEP5_DATA\"), \"GET_STEP6_DATA\", \"GET_STEP6_DATA\"), \"GET_STEP7_DATA\", \"GET_STEP7_DATA\"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_endpoints, \"GET_STEP9_DATA\", \"GET_STEP9_DATA\"), \"GET_STEP11_DATA\", \"GET_STEP11_DATA\"), \"GET_STEP11_FILE\", \"GET_STEP11_FILE\"), \"UPDATE_POLICY_STEP1\", \"UPDATE_POLICY_STEP1\"), \"GET_ISURED_PERSONS\", \"GET_ISURED_PERSONS\"), \"UPDATE_PARTY\", \"UPDATE_PARTY\"), \"GET_POLICY_DETAILS\", \"GET_POLICY_DETAILS\"), \"UPDATE_PAYMENTS\", \"UPDATE_PAYMENTS\"), \"CREATE_POLICY_RISK\", \"CREATE_POLICY_RISK\"), \"ACTIVATE_POLICY\", \"ACTIVATE_POLICY\"), _defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_endpoints, \"COMPLETE_POLICY\", \"COMPLETE_POLICY\"), \"SET_POLICY_BUILDING\", \"SET_POLICY_BUILDING\"), \"SEARCH_POLICIES\", \"SEARCH_POLICIES\"), \"SEARCH_POLICY_GENERAL_CONDITIONS\", \"SEARCH_POLICY_GENERAL_CONDITIONS\"), \"GET_ASSURED_LIST\", \"GET_ASSURED_LIST\"), \"GET_ADHERENTS\", \"GET_ADHERENTS\"), \"GET_ADHERENTS_BY_OWNER\", \"GET_ADHERENTS_BY_OWNER\"), \"GET_OWNERS\", \"GET_OWNERS\"), \"GET_POLICY_ROLES\", \"GET_POLICY_ROLES\"), \"CREATE_PRODUCT\", \"CREATE_PRODUCT\"));\nvar services = [{\n endpoint: endpoints.SEARCH_INDIVIDUALS,\n serviceName: \"individuals\",\n url: \"party/v1/individuals\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.CREATE_INDIVIDUAL,\n serviceName: \"individuals\",\n url: \"party/v1/individuals\",\n method: methods.POST,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ACTIVITIES,\n serviceName: \"activities\",\n url: \"party/v1/activities/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_PRACTICES,\n serviceName: \"practices\",\n url: \"party/v1/practices/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_SECTORS,\n serviceName: \"sectors\",\n url: \"party/v1/sectors\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_FISCAL_CATEGORIES,\n serviceName: \"fiscal-categories\",\n url: \"party/v1/fiscal-categories?party-type-code={0}&country-code={1}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_MAIL_TYPES,\n serviceName: \"mail-types\",\n url: \"party/v1/mail-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_PHONE_TYPES,\n serviceName: \"phone-types\",\n url: \"party/v1/phone-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_IDENTIFICATION_TYPES,\n serviceName: \"identification-types\",\n url: \"party/v1/identification-types?party-type-code={0}&country-code={1}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_RELATIONS,\n serviceName: \"parties/relations\",\n url: \"party/v1/parties/{0}/relations\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_NOTES,\n serviceName: \"parties/notes\",\n url: \"party/v1/parties/{0}/notes\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_FILES,\n serviceName: \"parties/files\",\n url: \"party/v1/parties/{0}/files\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.UPDATE_NOTES,\n serviceName: \"parties/notes\",\n url: \"party/v1/parties/{0}/notes\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.UPDATE_FILES,\n serviceName: \"parties/files\",\n url: \"party/v1/parties/{0}/files\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.ADD_RELATION_WITH_EXISTING_PARTY,\n serviceName: \"parties/relations\",\n url: \"party/v1/parties/{0}/relations\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_RELATIONS_BY_PARTY_CODE,\n serviceName: \"parties/relations\",\n url: \"party/v1/parties/{0}/relations\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.REMOVE_RELATION,\n serviceName: \"parties/relations/disable\",\n url: \"party/v1/parties/{0}/relations/disable\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_FILE,\n serviceName: \"parties/file\",\n url: \"party/v1/parties/{0}/file/{1}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.SEARCH_ORGANIZATION,\n serviceName: \"organisations\",\n url: \"party/v1/organisations\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ORGANIZATION_TYPES,\n serviceName: \"organisation-types\",\n url: \"party/v1/organisation-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.CREATE_ORGANIZATION,\n serviceName: \"organisations\",\n url: \"party/v1/organisations\",\n method: methods.POST,\n module: modules.PARTY\n}, {\n endpoint: endpoints.UPDATE_ORGANIZATION,\n serviceName: \"organisations\",\n url: \"party/v1/organisations/{0}\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ORGANIZATION_BY_CODE,\n serviceName: \"organisations\",\n url: \"party/v1/organisations/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.ADD_RELATION_WITH_NEW_ORGANIZATION,\n serviceName: \"organisations/relations\",\n url: \"party/v1/organisations/{0}/relations\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.UPDATE_PERSON,\n serviceName: \"individuals\",\n url: \"party/v1/individuals/{0}\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.SEARCH_PERSON,\n serviceName: \"individuals\",\n url: \"party/v1/individuals\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_PERSON_BY_CODE,\n serviceName: \"individuals\",\n url: \"party/v1/individuals/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_GENDERS,\n serviceName: \"genders\",\n url: \"party/v1/genders\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_MARITAL_STATUSES,\n serviceName: \"marital-statuses\",\n url: \"party/v1/marital-statuses\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_WORKER_TYPES,\n serviceName: \"worker-types\",\n url: \"party/v1/worker-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ECONOMIC_CLASSES,\n serviceName: \"economic-classes\",\n url: \"party/v1/economic-classes\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_RELATION_TYPES,\n serviceName: \"relation-types\",\n url: \"party/v1/relation-types/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.ADD_RELATION_WITH_NEW_PERSON,\n serviceName: \"individuals/relations\",\n url: \"party/v1/individuals/{0}/relations\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_POLICY_PROCESSES,\n serviceName: \"policy-statuses\",\n url: \"policy/v1/policy-statuses\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_COUNTRIES,\n serviceName: \"countries\",\n url: \"location/v1/countries\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_COUNTRY_BY_CODE,\n serviceName: \"countries\",\n url: \"location/v1/countries/{0}\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_PROVINCES,\n serviceName: \"countries/provinces\",\n url: \"location/v1/countries/{0}/provinces\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_CITIES,\n serviceName: \"provinces/cities\",\n url: \"location/v1/provinces/{0}/cities\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_POSTAL_CODES,\n serviceName: \"cities/postal-codes\",\n url: \"location/v1/cities/{0}/postal-codes\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ADDRESSES_BY_PARTY_CODE,\n serviceName: \"party/addresses\",\n url: \"location/v1/party/{0}/addresses\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_ADDRESS_TYPES,\n serviceName: \"address-types\",\n url: \"location/v1/address-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_PAYMENT_METHODS_BY_PARTY_CODE,\n serviceName: \"parties/payment-methods\",\n url: \"party/v1/parties/{0}/payment-methods\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_CREDIT_CARD_TYPES,\n serviceName: \"credit-card-types\",\n url: \"finance/v1/credit-card-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_CARD_PROVIDERS,\n serviceName: \"card-providers\",\n url: \"finance/v1/card-providers\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.UPDATE_PAYMENTS,\n serviceName: \"parties/payment-methods\",\n url: \"party/v1/parties/{0}/payment-methods\",\n method: methods.PUT,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_BANKS,\n serviceName: \"banks\",\n url: \"finance/v1/banks\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_CURRENCIES,\n serviceName: \"currencies\",\n url: \"finance/v1/currencies\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_BANK_ACCOUNT_TYPES,\n serviceName: \"bank-account-types\",\n url: \"finance/v1/bank-account-types\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.GET_BANK_BRANCHES,\n serviceName: \"banks/branches\",\n url: \"finance/v1/banks/{0}/branches\",\n method: methods.GET,\n module: modules.PARTY\n}, {\n endpoint: endpoints.SEARCH_INTERMEDIARIES,\n serviceName: \"intermediary\",\n url: \"intermediary/v1/intermediary\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_PERSON_INTERMEDIARY_BY_CODE,\n serviceName: \"intermediary-individual\",\n url: \"intermediary/v1/intermediary-individual/{0}\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_ORGANIZATION_INTERMEDIARY_BY_CODE,\n serviceName: \"intermediary-organisation\",\n url: \"intermediary/v1/intermediary-organisation/{0}\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_INTERMEDIARIES_GROUPS,\n serviceName: \"intermediary-groups\",\n url: \"intermediary/v1/intermediary-groups\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_INTERMEDIARIES_ROLES,\n serviceName: \"intermediary-roles\",\n url: \"intermediary/v1/intermediary-roles\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_INTERMEDIARY_STRUCTURES,\n serviceName: \"intermediary-structures\",\n url: \"intermediary/v1/intermediary/{0}/commercial-structures\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_INTERMEDIARIES_STATES,\n serviceName: \"commercial-structure-statuses\",\n url: \"intermediary/v1/commercial-structure-statuses\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.GET_INTERMEDIARIES_TYPES,\n serviceName: \"intermediary-types\",\n url: \"intermediary/v1/intermediary-types\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.CREATE_INTERMEDIARY_ASSOCIATED_WITH_PARTY,\n serviceName: \"intermediary-party-association\",\n url: \"intermediary/v1/intermediary-party-association\",\n method: methods.POST,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.CREATE_INTERMEDIARY_WITH_WITH_PERSON,\n serviceName: \"intermediary-individual\",\n url: \"intermediary/v1/intermediary-individual\",\n method: methods.POST,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.CREATE_INTERMEDIARY_WITH_WITH_ORGANIZATION,\n serviceName: \"intermediary-organisation\",\n url: \"intermediary/v1/intermediary-organisation\",\n method: methods.POST,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.UPDATE_INTERMEDIARY,\n serviceName: \"intermediary\",\n url: \"intermediary/v1/intermediary/{0}\",\n method: methods.PUT,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.SEARCH_COMMERCIAL_STRUCTURE,\n serviceName: \"commercial-structures\",\n url: \"intermediary/v1/commercial-structures\",\n method: methods.GET,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.CREATE_COMMERCIAL_STRUCTURE,\n serviceName: \"commercial-structures\",\n url: \"intermediary/v1/commercial-structures\",\n method: methods.POST,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.GET_COMMERCIAL_STRUCTURE_STATUSES,\n serviceName: \"commercial-structure-statuses\",\n url: \"intermediary/v1/commercial-structure-statuses\",\n method: methods.GET,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.GET_COMMERCIAL_STRUCTURES_BY_CODE,\n serviceName: \"commercial-structures\",\n url: \"intermediary/v1/commercial-structures/{0}\",\n method: methods.GET,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.UPDATE_COMMERCIAL_STRUCTURE,\n serviceName: \"commercial-structures\",\n url: \"intermediary/v1/commercial-structures/{0}\",\n method: methods.PUT,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.UPDATE_COMMERCIAL_STRUCTURE_INTERMEDIARIES,\n serviceName: \"commercial-structures/intermediaries\",\n url: \"intermediary/v1/commercial-structures/{0}/intermediaries\",\n method: methods.PUT,\n module: modules.COMMERCIAL_STRUCTURE\n}, {\n endpoint: endpoints.SEARCH_POLICIES,\n serviceName: \"policies\",\n url: \"policy/v1/policies\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_SECTIONS,\n serviceName: \"sections\",\n url: \"product/v1/sections\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_SUBSECTIONS,\n serviceName: \"sections/subsections\",\n url: \"product/v1/sections/{0}/subsections\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_PROCESSES,\n serviceName: \"policy-statuses\",\n url: \"policy/v1/policy-statuses\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_PRODUCTS,\n serviceName: \"subsections/products\",\n url: \"product/v1/subsections/{0}/products\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_VALIDITY_TYPES,\n serviceName: \"policy-validities\",\n url: \"policy/v1/policy-validities\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_CARACTERS,\n serviceName: \"wording-types\",\n url: \"product/v1/wording-types\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.SEARCH_POLICY_GENERAL_CONDITIONS,\n serviceName: \"wordings\",\n url: \"/product/v1/products/{0}/wordings\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_TYPE_OF_DOCUMENTATION,\n serviceName: \"file-types\",\n url: \"policy/v1/file-types\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_PAYMENT_FREQUENCIES,\n serviceName: \"payment-frequencies\",\n url: \"policy/v1/payment-frequencies\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ASSOCIATE_TERMS_CONDITION,\n serviceName: \"terms\",\n url: \"policy/v1/policies/{0}/terms\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ASSOCIATE_EXPENSES,\n serviceName: \"expenses\",\n url: \"policy/v1/policies/{0}/expenses\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ASSOCIATE_COVERAGE,\n serviceName: \"coverages\",\n url: \"policy-life/v1/policies/{0}/coverages\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_COVERAGES,\n serviceName: \"coverages\",\n url: \"product/v1/products/{0}/coverages\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_EXPENSEVALUES,\n serviceName: \"expenses\",\n url: \"/product/v1/products/{0}/expenses\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_MORTALITY_TABLE,\n serviceName: \"mortality-tables\",\n url: \"policy-life/v1/mortality-tables\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP1,\n serviceName: \"policies\",\n url: \"policy/v1/policies\",\n method: methods.POST,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP2,\n serviceName: \"policies/roles\",\n url: \"policy/v1/policies/{0}/roles\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP3,\n serviceName: \"policies/collections\",\n url: \"policy/v1/policies/{0}/collections\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP4,\n serviceName: \"policies/commercial-structures\",\n url: \"policy/v1/policies/{0}/commercial-structures\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP5,\n serviceName: \"policies/products\",\n url: \"policy-life/v1/policies/{0}/products\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP6,\n serviceName: \"policies/coverages\",\n url: \"policy-life/v1/policies/{0}/coverages\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP7,\n serviceName: \"policies/insurables\",\n url: \"policy-life/v1/policies/{0}/insurables\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP8,\n serviceName: \"policies/expenses\",\n url: \"policy/v1/policies/{0}/expenses\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP9,\n serviceName: \"policies/wordings\",\n url: \"policy/v1/policies/{0}/wordings\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP10,\n serviceName: \"policies/terms\",\n url: \"policy/v1/policies/{0}/terms\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_STEP11,\n serviceName: \"policies/documentation\",\n url: \"policy/v1/policies/{0}/documentation\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP1_DATA,\n serviceName: \"policies\",\n url: \"policy/v1/policies/{0}\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP2_DATA,\n serviceName: \"policies/roles\",\n url: \"policy/v1/policies/{0}/roles\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP3_DATA,\n serviceName: \"policies/collections\",\n url: \"policy/v1/policies/{0}/collections\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP4_DATA,\n serviceName: \"policies/commercial-structures\",\n url: \"policy/v1/policies/{0}/commercial-structures\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP5_DATA,\n serviceName: \"policies/products\",\n url: \"policy/v1/policies/{0}/products\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP6_DATA,\n serviceName: \"policies/coverages\",\n url: \"policy-life/v1/policies/{0}/coverages\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP7_DATA,\n serviceName: \"policies/insurables\",\n url: \"policy-life/v1/policies/{0}/insurables\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP9_DATA,\n serviceName: \"policies/wordings\",\n url: \"policy/v1/policies/{0}/wordings\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP11_DATA,\n serviceName: \"policies/documentation\",\n url: \"policy/v1/policies/{0}/documentation\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_STEP11_FILE,\n serviceName: \"policies/file\",\n url: \"policy/v1/policies/{0}/file/{1}\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.UPDATE_POLICY_STEP1,\n serviceName: \"policies\",\n url: \"policy/v1/policies/{0}\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ISURED_PERSONS,\n serviceName: \"insurables\",\n url: \"policy-life/v1/products/{0}/insurables\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.UPDATE_PARTY,\n serviceName: \"parties\",\n url: \"policy/v1/parties/{0}\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_DETAILS,\n serviceName: \"policies/details\",\n url: \"policy-life/v1/policies/{0}/details\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.UPDATE_PAYMENTS,\n serviceName: \"policies/collections\",\n url: \"policy/v1/policies/collections\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.CREATE_POLICY_RISK,\n serviceName: \"policies\",\n url: \"policy-life/v1/policies/{0}/insureds\",\n method: methods.POST,\n module: modules.POLICY\n}, {\n endpoint: endpoints.ACTIVATE_POLICY,\n serviceName: \"policies/activate\",\n url: \"policy-life/v1/policies/{0}/activate\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.COMPLETE_POLICY,\n serviceName: \"policies/complete\",\n url: \"/policy-life/v1/policies/{0}/complete\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.SET_POLICY_BUILDING,\n serviceName: \"policies/build\",\n url: \"policy-life/v1/policies/{0}/build\",\n method: methods.PUT,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_POLICY_ROLES,\n serviceName: \"policies/roles\",\n url: \"policy/v1/policies/{0}/roles\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ASSURED_LIST,\n serviceName: \"insureds\",\n url: \"policy-life/v1/policies/{0}/insureds\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ADHERENTS,\n serviceName: \"adherents\",\n url: \"policy-life/v1/adherents/{0}\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_OWNERS,\n serviceName: \"owners\",\n url: \"policy-life/v1/owners/{0}\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.GET_ADHERENTS_BY_OWNER,\n serviceName: \"owners/adherents\",\n url: \"policy-life/v1/owners/{0}/adherents\",\n method: methods.GET,\n module: modules.POLICY\n}, {\n endpoint: endpoints.SEARCH_ACCOUNT_OFFICERS,\n serviceName: \"account-officers\",\n url: \"intermediary/v1/account-officers\",\n method: methods.GET,\n module: modules.INTERMEDIARY\n}, {\n endpoint: endpoints.CREATE_PRODUCT,\n serviceName: \"configurator-product-creation\",\n // modificar cuando agregan service para modulo configurator\n url: \"policy-life/v1/products\",\n method: methods.POST,\n module: modules.CONFIGURATOR\n}];\n\n//# sourceURL=webpack://sysone-api-mapper/./servicesData.js?");
50
+
51
+ /***/ }),
52
+
53
+ /***/ "./src/mapper/Mapper.js":
54
+ /*!******************************!*\
55
+ !*** ./src/mapper/Mapper.js ***!
56
+ \******************************/
57
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
58
+
59
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ apiMapper: () => (/* binding */ apiMapper),\n/* harmony export */ configureApiMapper: () => (/* binding */ configureApiMapper)\n/* harmony export */ });\n/* harmony import */ var _axiosInstance__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../axiosInstance */ \"./axiosInstance.js\");\n/* harmony import */ var _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./endpointsConfig */ \"./src/mapper/endpointsConfig.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nvar _excluded = [\"mappedParams\", \"responseType\", \"headers\"];\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction _objectWithoutProperties(e, t) { if (null == e) return {}; var o, r, i = _objectWithoutPropertiesLoose(e, t); if (Object.getOwnPropertySymbols) { var n = Object.getOwnPropertySymbols(e); for (r = 0; r < n.length; r++) o = n[r], -1 === t.indexOf(o) && {}.propertyIsEnumerable.call(e, o) && (i[o] = e[o]); } return i; }\nfunction _objectWithoutPropertiesLoose(r, e) { if (null == r) return {}; var t = {}; for (var n in r) if ({}.hasOwnProperty.call(r, n)) { if (-1 !== e.indexOf(n)) continue; t[n] = r[n]; } return t; }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\n\nvar apiConfig = null;\nvar configureApiMapper = function configureApiMapper(config) {\n if (!(config !== null && config !== void 0 && config.baseURL)) {\n throw new Error(\"apiMapper requires baseURL\");\n }\n apiConfig = {\n baseURL: config.baseURL,\n headers: config.headers || {}\n };\n};\nvar getConfig = function getConfig() {\n if (!apiConfig) {\n throw new Error(\"apiMapper not configured. Call configureApiMapper() first.\");\n }\n return apiConfig;\n};\n\n/**\r\n * Normaliza tenant (ej: \"cnp/foo\" → \"cnp\")\r\n */\nvar normalizeTenant = function normalizeTenant(tenant) {\n if (!tenant || typeof tenant !== \"string\") return tenant;\n return tenant.split(\"/\")[0];\n};\nvar getUrl = function getUrl(serviceUrl, routeParams) {\n if (!routeParams || routeParams.length === 0) return serviceUrl;\n return serviceUrl.replace(/{(\\d+)}/g, function (match, index) {\n return routeParams[index] !== undefined ? routeParams[index] : match;\n });\n};\nvar apiMapper = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(endpointCode, tenant, routeParams) {\n var _configData$normalize;\n var params,\n additionalHeaders,\n configData,\n normalizedTenant,\n endpointData,\n _getConfig,\n baseURL,\n headers,\n axiosConfig,\n url,\n _endpointData$request,\n mappedParams,\n responseType,\n requestHeaders,\n otherOptions,\n response,\n _endpointData$request2,\n mappedPostParams,\n mappedBody,\n _requestHeaders,\n _response,\n _response2,\n _response3,\n _args = arguments;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n params = _args.length > 3 && _args[3] !== undefined ? _args[3] : null;\n additionalHeaders = _args.length > 4 && _args[4] !== undefined ? _args[4] : {};\n /* -------- Endpoint config -------- */\n configData = _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__.tenantsConfig[endpointCode];\n if (configData) {\n _context.next = 5;\n break;\n }\n throw new Error(\"Endpoint no configurado: \".concat(endpointCode));\n case 5:\n normalizedTenant = normalizeTenant(tenant);\n endpointData = (_configData$normalize = configData[normalizedTenant]) !== null && _configData$normalize !== void 0 ? _configData$normalize : configData[\"default\"];\n if (endpointData) {\n _context.next = 9;\n break;\n }\n throw new Error(\"No hay configuraci\\xF3n para endpoint \".concat(endpointCode, \" y tenant \").concat(normalizedTenant));\n case 9:\n /* -------- Axios config -------- */\n _getConfig = getConfig(), baseURL = _getConfig.baseURL, headers = _getConfig.headers;\n axiosConfig = {\n baseURL: baseURL,\n headers: _objectSpread(_objectSpread({}, headers), additionalHeaders),\n validateStatus: function validateStatus(s) {\n return s < 500;\n }\n };\n url = getUrl(endpointData.url, routeParams);\n /* -------- Request -------- */\n _context.t0 = endpointData.method;\n _context.next = _context.t0 === _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__.methods.GET ? 15 : _context.t0 === _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__.methods.POST ? 20 : _context.t0 === _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__.methods.PUT ? 25 : _context.t0 === _endpointsConfig__WEBPACK_IMPORTED_MODULE_1__.methods.DELETE ? 29 : 33;\n break;\n case 15:\n _endpointData$request = endpointData.requestMapper(params), mappedParams = _endpointData$request.mappedParams, responseType = _endpointData$request.responseType, requestHeaders = _endpointData$request.headers, otherOptions = _objectWithoutProperties(_endpointData$request, _excluded);\n _context.next = 18;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_0__[\"default\"].get(url, _objectSpread(_objectSpread({}, axiosConfig), {}, {\n params: mappedParams,\n responseType: responseType,\n headers: _objectSpread(_objectSpread({}, axiosConfig.headers), requestHeaders)\n }, otherOptions));\n case 18:\n response = _context.sent;\n return _context.abrupt(\"return\", endpointData.responseMapper(response));\n case 20:\n _endpointData$request2 = endpointData.requestMapper(params), mappedPostParams = _endpointData$request2.mappedPostParams, mappedBody = _endpointData$request2.mappedBody, _requestHeaders = _endpointData$request2.headers;\n _context.next = 23;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_0__[\"default\"].post(url, mappedBody, _objectSpread(_objectSpread({}, axiosConfig), {}, {\n params: mappedPostParams,\n headers: _objectSpread(_objectSpread({}, axiosConfig.headers), _requestHeaders)\n }));\n case 23:\n _response = _context.sent;\n return _context.abrupt(\"return\", endpointData.responseMapper(_response.data));\n case 25:\n _context.next = 27;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_0__[\"default\"].put(url, params, axiosConfig);\n case 27:\n _response2 = _context.sent;\n return _context.abrupt(\"return\", endpointData.responseMapper(_response2.data));\n case 29:\n _context.next = 31;\n return _axiosInstance__WEBPACK_IMPORTED_MODULE_0__[\"default\"][\"delete\"](url, _objectSpread(_objectSpread({}, axiosConfig), {}, {\n data: params\n }));\n case 31:\n _response3 = _context.sent;\n return _context.abrupt(\"return\", endpointData.responseMapper(_response3.data));\n case 33:\n throw new Error(\"HTTP method not supported\");\n case 34:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n return function apiMapper(_x, _x2, _x3) {\n return _ref.apply(this, arguments);\n };\n}();\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/Mapper.js?");
60
+
61
+ /***/ }),
62
+
63
+ /***/ "./src/mapper/endpointsConfig.js":
64
+ /*!***************************************!*\
65
+ !*** ./src/mapper/endpointsConfig.js ***!
66
+ \***************************************/
67
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
68
+
69
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ methods: () => (/* binding */ methods),\n/* harmony export */ tenantsConfig: () => (/* binding */ tenantsConfig)\n/* harmony export */ });\n/* harmony import */ var _modules_billing__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./modules/billing */ \"./src/mapper/modules/billing/index.js\");\n/* harmony import */ var _modules_claim__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./modules/claim */ \"./src/mapper/modules/claim/index.js\");\n/* harmony import */ var _modules_general__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ./modules/general */ \"./src/mapper/modules/general/index.js\");\n/* harmony import */ var _modules_party__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ./modules/party */ \"./src/mapper/modules/party/index.js\");\n/* harmony import */ var _modules_policy__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ./modules/policy */ \"./src/mapper/modules/policy/index.js\");\n/* harmony import */ var _modules_quotation__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ./modules/quotation */ \"./src/mapper/modules/quotation/index.js\");\n/* harmony import */ var _modules_request__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(/*! ./modules/request */ \"./src/mapper/modules/request/index.js\");\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n// Import modules organized by functionality\n\n\n\n\n\n\n\nvar methods = {\n GET: \"GET\",\n POST: \"POST\",\n PUT: \"PUT\",\n DELETE: \"DELETE\"\n};\n\n// ============================================================================\n// CONFIGURATION MODULE\n// ============================================================================\nvar configurationModule = {\n GET_MODULES: {\n \"default\": {\n url: 'ui-configuration/v1/platforms/link-one/modules',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'ui-configuration/v1/modules',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_general__WEBPACK_IMPORTED_MODULE_2__.getModules_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_POWERBI_TOKEN: {\n cnp: {\n url: 'ui-configuration/v1/embedded-reports',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n }\n};\n\n// ============================================================================\n// BILLING MODULE\n// ============================================================================\nvar billingModule = {\n GET_BILLINGS: {\n \"default\": {\n url: 'billing/v1/billing',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy/{0}/{1}/payments',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getBillingsParams)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getBillingsResponse)(response.data);\n }\n }\n },\n GET_POLICY_COLLECTIONS: {\n \"default\": {\n url: '/collection/v1/collections',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy/{0}/{1}/payments',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getBillingsParams)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getCollecionsResponse)(response.data);\n }\n }\n },\n GET_DEBTORS: {\n \"default\": {\n url: 'billing/v1/billing',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy/{0}/{1}/payments',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getBillingsParams)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getDebtorsResponse)(response.data);\n }\n }\n },\n GET_BILLING_TYPE: {\n \"default\": {\n url: 'billing/v1/billing-types',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/genders',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_billing__WEBPACK_IMPORTED_MODULE_0__.getBillingTypeResponse)(response.data);\n }\n }\n }\n};\n\n// ============================================================================\n// INTERMEDIARY MODULE\n// ============================================================================\nvar intermediaryModule = {\n GET_INTERMEDIARY_STRUCTURE: {\n \"default\": {\n url: 'intermediary/v1/intermediary/{0}/commercial-structures',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_INTERMEDIARY_BY_CODE: {\n \"default\": {\n url: 'intermediary/v1/intermediary/{0}',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_COMMERCIAL_STRUCTURE: {\n \"default\": {\n url: 'intermediary/v1/commercial-structures',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n }\n};\n\n// ============================================================================\n// PARTY MODULE\n// ============================================================================\nvar partyModule = {\n GET_CURRENCIES: {\n \"default\": {\n url: 'finance/v1/currencies',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/currencies',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-currencies\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_GENDERS: {\n \"default\": {\n url: 'party/v1/genders',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1genders/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/genders',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getGenders)(response.data);\n }\n }\n },\n GET_IDENTIFICATION_TYPES: {\n \"default\": {\n url: 'party/v1/identification-types',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1identification-types/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/identification-types',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-identification-types\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getIdentificationTypes)(response.data);\n }\n }\n },\n GET_COUNTRIES: {\n \"default\": {\n url: 'location/v1/countries',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/location/v1/open-api.html#/paths/~1v1~1countries/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/countries',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-countries\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getCountries)(response.data);\n }\n }\n },\n GET_PROVINCES: {\n \"default\": {\n url: 'location/v1/countries/{0}/provinces',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/location/v1/open-api.html#/paths/~1v1~1countries/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/countries/{0}/provinces',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-countries\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getProvinces)(response.data);\n }\n }\n },\n GET_MARITAL_STATUS: {\n \"default\": {\n url: 'party/v1/marital-statuses',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1marital-statuses/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/marital-statuses',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-marital-statuses\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getMaritalStatuses)(response.data);\n }\n }\n },\n GET_ACTIVITY: {\n \"default\": {\n url: 'party/v1/sectors',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1sectors/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/activities',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=get-v1-activity\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getActivityList)(response.data);\n }\n }\n },\n GET_BLOOD_PRESSURES: {\n cnp: {\n url: 'party/v1/blood-pressures',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-blood-pressures\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_PAYMENT_FRECUENCIES: {\n \"default\": {\n url: 'quotation/v1/payment-frequencies',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/payment-frequencies',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-payment-frequencies\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getPaymentFrecuencies)(response.data);\n }\n }\n },\n GET_PAYMENT_TYPES: {\n cnp: {\n url: 'party/v1/payment-types',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-payment-types\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_BRANCHES: {\n cnp: {\n url: 'party/v1/branches',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-branches\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_PARTIES: {\n \"default\": {\n url: 'party/v1/{0}',\n method: methods.GET,\n source: \"https://apidoc.sysone.com/party/v1/open-api.html#/paths/~1v1~1individuals/get\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/parties',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-parties\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.partySearchParams)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.partySearch)(response.data);\n }\n }\n },\n POST_AGE: {\n \"default\": {\n url: '',\n method: methods.POST,\n source: '',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: 'party/v1/age',\n method: methods.POST,\n source: 'https://developers-test.cnp.com.ar/api-details#api=party-api&operation=post-v1-age',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n }\n};\n\n// ============================================================================\n// PRODUCT MODULE\n// ============================================================================\nvar productModule = {\n GET_COVERAGES: {\n \"default\": {\n url: 'product/v1/products/{0}/coverages',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/products/{0}/coverages',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-products-code-coverages-currencycode-currencycode-smoker-smoker\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getCoverages)(response.data);\n }\n }\n },\n GET_DISTRIBUTION_LIMITS: {\n cnp: {\n url: 'party/v1/products/{0}/savings-distribution',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-products-code-coverages-currencycode-currencycode-smoker-smoker\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_PRODUCTS_BY_SUBSECTIONS: {\n \"default\": {\n url: 'product/v1/products',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/product/v1/open-api.html#/paths/~1v1~1products/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'party/v1/subsections/{0}/products',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-subsections-code-products\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_party__WEBPACK_IMPORTED_MODULE_3__.getProductsBySubsections_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getProductsBySubsections)(response.data);\n }\n }\n },\n GET_PRODUCT_PARAMETERS: {\n cnp: {\n url: \"party/v1/products/{0}\",\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getProductParameters)(response.data);\n }\n }\n },\n GET_MONETARY_GOALS: {\n cnp: {\n url: 'party/v1/products/{0}/monetary-goals',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-monetary-goals\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_SAVINGS_DISTRIBUTION: {\n cnp: {\n url: 'party/v1/products/{0}/savings-distribution',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-products-code-savings-distribution-goalcode-goalcode-goalamount-goala\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_QUOTATION_BENEFITS: {\n cnp: {\n url: 'party/v1/quotation-benefits',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=party-api&operation=get-v1-quotation-benefits\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n }\n};\n\n// ============================================================================\n// POLICY MODULE\n// ============================================================================\nvar policyModule = {\n GET_ENDORSEMENTS: {\n \"default\": {\n url: 'policy/v1/policies/{0}/endorsements',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1endorsements/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy/{0}/{1}/endorsements',\n method: methods.GET,\n source: 'https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-policy-number-section-code-endorsements',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getEndorsements_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getEndorsements_CNP)(response.data);\n }\n }\n },\n GET_INSUREDS: {\n \"default\": {\n url: '{0}/v1/policies/{1}/insureds',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy-life/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1insureds/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy/{0}/{1}/policy-insured',\n method: methods.GET,\n source: 'https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-policy-number-section-code-insureds',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getInsureds_CNP_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getInsureds_CNP)(response.data);\n }\n }\n },\n GET_POLICIES: {\n \"default\": {\n url: 'policy/v1/policies',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-pagenumber-pagenumber-sort-sort-ordertype-ordertype-pagesize-p\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicies_CNP_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicies_CNP)(response.data);\n }\n }\n },\n GET_POLICY_DETAIL: {\n \"default\": {\n url: '/{0}/v1/policies/{1}/details',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyDetail_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyDetail_CNP)(response.data);\n }\n }\n },\n GET_COLLECTIONS: {\n \"default\": {\n url: '/policy/v1/policies/{0}/collections',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollection_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollection)(response.data);\n }\n }\n },\n GET_POLICY_HOME_COLLECTIVE_DETAIL: {\n \"default\": {\n url: 'policy-home/v1/policies/{0}/details',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollectiveDetail_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollectiveDetail_CNP)(response.data);\n }\n }\n },\n GET_POLICY_HOME_INDIVIDUAL_DETAIL: {\n \"default\": {\n url: 'policy-home/v1/policies/{0}/details',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyIndividualDetail_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyDetail_CNP)(response.data);\n }\n }\n },\n GET_POLICY_LIFE_COLLECTIVE_DETAIL: {\n \"default\": {\n url: 'policy-life/v1/policies/{0}/details',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollectiveDetail_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyCollectiveDetail_CNP)(response.data);\n }\n }\n },\n GET_POLICY_LIFE_INDIVIDUAL_DETAIL: {\n \"default\": {\n url: 'policy-life/v1/policies/{0}/details',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/policy/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1details/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'policy/v1/policy-individual/{0}/{1}/detail',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=get-v1-policy-individual-policy-number-section-code-detail\",\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyIndividualDetail_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.getPolicyDetail_CNP)(response.data);\n }\n }\n },\n GET_POLICY_STATUSES: {\n \"default\": {\n url: 'policy/v1/policy-statuses',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_BENEFICIRY_TYPES: {\n cnp: {\n url: 'policy/v1/beneficiary-types',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n POST_INSURED_UPDATE: {\n \"default\": {\n url: 'policy-life/v1/policies/{0}/insureds',\n method: methods.POST,\n requestMapper: null,\n source: 'https://apidoc.sysone.com/policy-life/v1/open-api.html#/paths/~1v1~1policies~1%7Bcode%7D~1insureds/post',\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: 'v1/policy-collective/{0}/{1}/insureds',\n method: methods.POST,\n requestMapper: null,\n source: 'https://developers-test.cnp.com.ar/api-details#api=policy-api&operation=post-v1-policy-collective-policy-number-section-code-insureds',\n responseMapper: function responseMapper(response) {\n return (0,_modules_policy__WEBPACK_IMPORTED_MODULE_4__.postInsureds_CNP)(response);\n }\n }\n }\n};\n\n// ============================================================================\n// CLAIM MODULE\n// ============================================================================\nvar claimModule = {\n GET_CLAIMS: {\n \"default\": {\n url: 'claim/v1/claims',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/claim/v1/open-api.html',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'claim/v1/claim',\n method: methods.GET,\n source: \"https://developers-test.cnp.com.ar/api-details#api=claim-api&operation=get-v1-claim-pagenumber-pagenumber-pagesize-pagesize\",\n requestMapper: null,\n responseMapper: function responseMapper(response) {\n return (0,_modules_claim__WEBPACK_IMPORTED_MODULE_1__.getClaims_CNP)(response.data);\n }\n }\n }\n};\n\n// ============================================================================\n// QUOTATION MODULE\n// ============================================================================\nvar quotationModule = {\n GET_QUOTATION_BY_CODE: {\n \"default\": {\n url: 'quotation/v1/quotations/{0}',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations~1%7Bcode%7D/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'quotation/v1/quotation/standard-plan/{0}',\n method: methods.GET,\n source: 'https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=get-v1-quotation-standard-plan-number',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getQuotationByCode_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getQuotationByCode)(response.data);\n }\n }\n },\n GET_QUOTATIONS: {\n \"default\": {\n url: 'quotation/v1/quotations',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'quotation/v1/quotations',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getQuotations_Request)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getQuotationsList)(response.data);\n }\n }\n },\n GET_QUOTATION_DETAILS: {\n \"default\": {\n url: '{0}/v1/quotations/{1}',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'quotation/v1/quotations/{0}',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.getQuotationDetail)(response.data);\n }\n }\n },\n GET_SWORN_STATEMENT: {\n cnp: {\n url: 'quotation/v1/quotations/{0}/questionnaires',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_QUOTATION_REPORT: {\n \"default\": {\n url: '{0}/v1/quotations/{1}/report',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request,\n responseType: \"arraybuffer\"\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: '/quotation/v1/quotations/{0}/report',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request,\n headers: {\n 'Accept': 'application/json'\n }\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_CREATE_QUOTATION_STANDARD_PLAN: {\n \"default\": {\n url: 'quotation/v1/quotations',\n method: methods.POST,\n source: 'https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/post',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: 'quotation/v1/quotation/standard-plan',\n method: methods.POST,\n source: 'https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=post-v1-quotation-standard-plan',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.quotationStandardPlanCreationMapped)(params)\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_CREATE_QUOTATION_VARIABLE_PLAN: {\n \"default\": {\n url: 'quotation/v1/quotations',\n method: methods.POST,\n source: 'https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/post',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: 'quotation/v1/quotation/variable-plan',\n method: methods.POST,\n source: 'https://developers-test.cnp.com.ar/api-details#api=quotation-api&operation=post-v1-quotation-variable-plan',\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: (0,_modules_quotation__WEBPACK_IMPORTED_MODULE_5__.quotationVariablePlanCreationMapped)(params)\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_CALCULATE_LS: {\n cnp: {\n url: 'quotation/v1/quotations/calculate',\n method: methods.POST,\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_CREATE_QUOTATION_LS: {\n cnp: {\n url: 'quotation/v1/quotations',\n method: methods.POST,\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n }\n};\n\n// ============================================================================\n// REQUEST MODULE\n// ============================================================================\nvar requestModule = {\n GET_REQUESTS_LOOKUP: {\n \"default\": {\n url: 'request/v1/requests',\n method: methods.GET,\n source: 'https://apidoc.sysone.com/quotation/v1/open-api.html#/paths/~1v1~1quotations/get',\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: 'request/v1/request/savings',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: (0,_modules_request__WEBPACK_IMPORTED_MODULE_6__.getRequest_Params)(request)\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n }\n },\n GET_REQUEST_DETAIL: {\n \"default\": {\n url: '{0}/v1/requests/{1}',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return response.data;\n }\n },\n cnp: {\n url: '/request/v1/request/savings/{0}',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request\n };\n },\n responseMapper: function responseMapper(response) {\n return (0,_modules_request__WEBPACK_IMPORTED_MODULE_6__.getRequestDetail)(response.data);\n }\n }\n },\n GET_REQUEST_REPORT: {\n \"default\": {\n url: '{0}/v1/policies/{1}/certificate',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request,\n responseType: \"arraybuffer\"\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n },\n cnp: {\n url: '/request/v1/request/savings/{0}/report',\n method: methods.GET,\n requestMapper: function requestMapper(request) {\n return {\n mappedParams: request,\n headers: {\n 'Accept': 'application/json'\n }\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_REQUEST_SIGNATURE: {\n cnp: {\n url: '/request/v1/request/savings/{0}/signature',\n method: methods.POST,\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n },\n POST_SEND_REQUEST: {\n cnp: {\n url: '/request/v1/request/savings',\n method: methods.POST,\n requestMapper: function requestMapper(params) {\n return {\n mappedBody: params\n };\n },\n responseMapper: function responseMapper(response) {\n return response;\n }\n }\n }\n};\n\n// ============================================================================\n// MAIN CONFIGURATION EXPORT\n// ============================================================================\nvar tenantsConfig = _objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread(_objectSpread({}, configurationModule), intermediaryModule), partyModule), productModule), policyModule), claimModule), quotationModule), requestModule), billingModule);\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/endpointsConfig.js?");
70
+
71
+ /***/ }),
72
+
73
+ /***/ "./src/mapper/helpers/mappingHelpers.js":
74
+ /*!**********************************************!*\
75
+ !*** ./src/mapper/helpers/mappingHelpers.js ***!
76
+ \**********************************************/
77
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
78
+
79
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ mapPaymentFrequency: () => (/* binding */ mapPaymentFrequency),\n/* harmony export */ mapProductCode: () => (/* binding */ mapProductCode),\n/* harmony export */ mapProvinceCode: () => (/* binding */ mapProvinceCode)\n/* harmony export */ });\nvar mapPaymentFrequency = function mapPaymentFrequency(frequencyCode) {\n var mapping = {\n 'ANNUAL': 6,\n 'MONTHLY': 1,\n 'QUARTERLY': 3,\n 'SEMI_ANNUAL': 5\n };\n return mapping[frequencyCode] || 6;\n};\nvar mapProductCode = function mapProductCode(productCode) {\n var mapping = {\n 'SC_SC': 534,\n 'VI_VI_VIDA_IND_1': 120,\n 'OTRO_CODIGO': 0\n };\n return mapping[productCode] || 404;\n};\nvar mapProvinceCode = function mapProvinceCode(provinceCode) {\n var mapping = {\n 'BS_AS': 1,\n 'CABA': 2\n };\n return mapping[provinceCode] || 0;\n};\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/helpers/mappingHelpers.js?");
80
+
81
+ /***/ }),
82
+
83
+ /***/ "./src/mapper/modules/billing/index.js":
84
+ /*!*********************************************!*\
85
+ !*** ./src/mapper/modules/billing/index.js ***!
86
+ \*********************************************/
87
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
88
+
89
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getBillingTypeResponse: () => (/* binding */ getBillingTypeResponse),\n/* harmony export */ getBillingsParams: () => (/* binding */ getBillingsParams),\n/* harmony export */ getBillingsResponse: () => (/* binding */ getBillingsResponse),\n/* harmony export */ getCollecionsResponse: () => (/* binding */ getCollecionsResponse),\n/* harmony export */ getDebtorsResponse: () => (/* binding */ getDebtorsResponse)\n/* harmony export */ });\nvar getBillingsParams = function getBillingsParams(i) {\n return {};\n};\nvar getBillingsResponse = function getBillingsResponse(data) {\n var values = data.paymentsEndorsement.flatMap(function (endorsement, index) {\n return endorsement.payments.map(function (payment, pIndex) {\n var _payment$expiration;\n return {\n id: \"\".concat(index + 1, \"-\").concat(pIndex + 1),\n // No tiene ID propio, uso el index + 1\n code: \"\".concat(index + 1, \"-\").concat(pIndex + 1),\n // No tiene código propio, uso el index + 1\n billingNumber: payment.installmentNumber,\n billingDate: payment.paymentDate,\n billingExpirationDate: (_payment$expiration = payment.expiration) !== null && _payment$expiration !== void 0 ? _payment$expiration : payment.expirationDate,\n totalAmount: payment.amount,\n remainingAmount: payment.debt,\n paymentStatus: {\n code: payment.amount < 0 ? \"UNPAID\" : \"PAID\",\n // ---- Si el monto es negativo esta pago???\n name: payment.amount < 0 ? \"Sin Pagar\" : \"Pagado\" // ---- Si el monto es negativo esta pago???\n },\n status: {},\n // ----- NO HAY STATUS\n name: \"Sin nombre del pagador\",\n // ----- NO HAY NOMBRE DEL PAGADOR\n policy: {},\n // ----- NO HAY DATOS DE POLIZA\n billingValuesGrouping: [{\n type: {\n name: \"Prima\",\n code: \"PRIME\"\n },\n value: payment.amount // ----- SOLO LLEGA LA PRIMA\n }],\n type: {\n name: \"Factura\",\n code: \"INVOICE\"\n },\n subtype: {},\n exchangeRate: null,\n billingDateFrom: \"N/A\",\n billingDateTo: \"N/A\",\n invoiceBarcode: payment.invoiceBarcode || null\n };\n });\n });\n return {\n values: values,\n total: values.length\n };\n};\nvar getDebtorsResponse = function getDebtorsResponse(data) {\n var values = data.paymentsEndorsement.flatMap(function (endorsement, index) {\n return endorsement.payments.map(function (payment, pIndex) {\n var _payment$expiration2;\n return {\n id: \"\".concat(index + 1, \"-\").concat(pIndex + 1),\n code: \"\".concat(index + 1, \"-\").concat(pIndex + 1),\n billingNumber: payment.installmentNumber,\n billingDate: payment.paymentDate,\n billingExpirationDate: (_payment$expiration2 = payment.expiration) !== null && _payment$expiration2 !== void 0 ? _payment$expiration2 : payment.expirationDate,\n totalAmount: payment.amount,\n remainingAmount: payment.debt,\n paymentStatus: {\n code: payment.debt < 0 ? \"UNPAID\" : \"PAID\",\n name: payment.debt < 0 ? \"Sin Pagar\" : \"Pagado\"\n },\n status: {},\n name: \"Sin nombre del pagador\",\n policy: {},\n billingValuesGrouping: [{\n type: {\n name: \"Prima\",\n code: \"PRIME\"\n },\n value: payment.amount\n }],\n type: {\n name: \"Factura\",\n code: \"INVOICE\"\n },\n subtype: {},\n exchangeRate: null,\n billingDateFrom: \"N/A\",\n billingDateTo: \"N/A\",\n invoiceBarcode: payment.invoiceBarcode || null\n };\n });\n }).filter(function (payment) {\n return (payment === null || payment === void 0 ? void 0 : payment.debt) > 0 || (payment === null || payment === void 0 ? void 0 : payment.remainingAmount) > 0;\n });\n return {\n values: values,\n total: values.length\n };\n};\nvar getCollecionsResponse = function getCollecionsResponse(data) {\n var values = data.paymentsEndorsement.flatMap(function (endorsement, index) {\n return endorsement.payments.map(function (payment, pIndex) {\n return {\n code: \"\".concat(index + 1, \"-\").concat(pIndex + 1),\n amount: payment.amount,\n applyAmount: payment.debt,\n collectionDate: payment.paymentDate,\n collectionNumber: payment.installmentNumber,\n currency: {\n name: \"Peso Argentino\",\n code: \"PESO_ARG\",\n mnemonic: \"ARS\",\n symbol: \"$\"\n },\n name: \"Sin nombre del pagador\",\n paymentType: null,\n policy: {},\n status: {},\n invoiceBarcode: payment.invoiceBarcode || null,\n rejectionReason: payment.rejectionReason || null,\n expirationDate: payment.expirationDate || null\n };\n });\n });\n return {\n values: values,\n total: values.length\n };\n};\nvar getBillingTypeResponse = function getBillingTypeResponse() {\n return {\n types: [{\n name: \"Factura\",\n code: \"INVOICE\",\n operator: null\n }]\n };\n};\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/billing/index.js?");
90
+
91
+ /***/ }),
92
+
93
+ /***/ "./src/mapper/modules/claim/index.js":
94
+ /*!*******************************************!*\
95
+ !*** ./src/mapper/modules/claim/index.js ***!
96
+ \*******************************************/
97
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
98
+
99
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getClaims_CNP: () => (/* binding */ getClaims_CNP)\n/* harmony export */ });\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nvar getClaims_CNP = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(response) {\n var _response$claims;\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n objectMapped = {\n values: response === null || response === void 0 || (_response$claims = response.claims) === null || _response$claims === void 0 ? void 0 : _response$claims.map(function (claim) {\n return {\n claimNumber: claim.claimNumber.toString(),\n policyNumber: claim.policyNumber,\n creationDate: claim.claimDate,\n status: {\n name: claim.status,\n code: \"N/A\"\n }\n };\n })\n };\n return _context.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n return function getClaims_CNP(_x) {\n return _ref.apply(this, arguments);\n };\n}();\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/claim/index.js?");
100
+
101
+ /***/ }),
102
+
103
+ /***/ "./src/mapper/modules/general/index.js":
104
+ /*!*********************************************!*\
105
+ !*** ./src/mapper/modules/general/index.js ***!
106
+ \*********************************************/
107
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
108
+
109
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getModules: () => (/* binding */ getModules),\n/* harmony export */ getModules_Request: () => (/* binding */ getModules_Request)\n/* harmony export */ });\nvar getModules = function getModules() {};\nvar getModules_Request = function getModules_Request(params) {\n return {\n roles: params.roles\n };\n};\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/general/index.js?");
110
+
111
+ /***/ }),
112
+
113
+ /***/ "./src/mapper/modules/party/index.js":
114
+ /*!*******************************************!*\
115
+ !*** ./src/mapper/modules/party/index.js ***!
116
+ \*******************************************/
117
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
118
+
119
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getCountries: () => (/* binding */ getCountries),\n/* harmony export */ getCoverages: () => (/* binding */ getCoverages),\n/* harmony export */ getGenders: () => (/* binding */ getGenders),\n/* harmony export */ getIdentificationTypes: () => (/* binding */ getIdentificationTypes),\n/* harmony export */ getMaritalStatuses: () => (/* binding */ getMaritalStatuses),\n/* harmony export */ getProductsBySubsections_Request: () => (/* binding */ getProductsBySubsections_Request),\n/* harmony export */ getProvinces: () => (/* binding */ getProvinces),\n/* harmony export */ partySearch: () => (/* binding */ partySearch),\n/* harmony export */ partySearchParams: () => (/* binding */ partySearchParams)\n/* harmony export */ });\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\nvar getIdentificationTypes = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n objectMapped = {\n values: response.types.map(function (a) {\n return {\n code: a.code,\n name: a.name\n };\n })\n };\n return _context.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n return function getIdentificationTypes(_x) {\n return _ref.apply(this, arguments);\n };\n}();\nvar getCountries = /*#__PURE__*/function () {\n var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee2$(_context2) {\n while (1) switch (_context2.prev = _context2.next) {\n case 0:\n objectMapped = {\n countries: response.countries.map(function (a) {\n return {\n code: a.code,\n name: a.name,\n areaCode: 'N/A'\n };\n })\n };\n return _context2.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context2.stop();\n }\n }, _callee2);\n }));\n return function getCountries(_x2) {\n return _ref2.apply(this, arguments);\n };\n}();\nvar getProvinces = /*#__PURE__*/function () {\n var _ref3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee3$(_context3) {\n while (1) switch (_context3.prev = _context3.next) {\n case 0:\n objectMapped = {\n provinces: response.provinces.map(function (a) {\n return {\n name: a.name,\n code: a.code,\n country: {\n code: a.country.code,\n name: a.country.name,\n areaCode: \"N/A\"\n }\n };\n })\n };\n return _context3.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context3.stop();\n }\n }, _callee3);\n }));\n return function getProvinces(_x3) {\n return _ref3.apply(this, arguments);\n };\n}();\nvar getMaritalStatuses = /*#__PURE__*/function () {\n var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee4$(_context4) {\n while (1) switch (_context4.prev = _context4.next) {\n case 0:\n objectMapped = {\n values: response.statuses.map(function (a) {\n return {\n name: a.name,\n code: a.code\n };\n })\n };\n return _context4.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context4.stop();\n }\n }, _callee4);\n }));\n return function getMaritalStatuses(_x4) {\n return _ref4.apply(this, arguments);\n };\n}();\nvar getGenders = /*#__PURE__*/function () {\n var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee5$(_context5) {\n while (1) switch (_context5.prev = _context5.next) {\n case 0:\n objectMapped = {\n values: response.genders.map(function (a) {\n return {\n name: a.name,\n code: a.code\n };\n })\n };\n return _context5.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context5.stop();\n }\n }, _callee5);\n }));\n return function getGenders(_x5) {\n return _ref5.apply(this, arguments);\n };\n}();\nvar getProductsBySubsections_Request = function getProductsBySubsections_Request(params) {\n return {\n subsectionCode: null\n };\n};\nvar partySearchParams = function partySearchParams(params) {\n return {\n firstName: params.firstName || params.name || null,\n lastName: params.lastName || null,\n identification: params.identificationValue || null\n };\n};\nvar partySearch = function partySearch(res) {\n var _res$parties;\n var objectMapped = {\n values: res === null || res === void 0 || (_res$parties = res.parties) === null || _res$parties === void 0 ? void 0 : _res$parties.map(function (party) {\n var _party$fullName, _party$identification, _party$identification2;\n // Separación por doble espacio\n var _ref6 = (party === null || party === void 0 || (_party$fullName = party.fullName) === null || _party$fullName === void 0 ? void 0 : _party$fullName.split(\" \")) || [],\n _ref7 = _slicedToArray(_ref6, 2),\n lastNamePart = _ref7[0],\n firstNamePart = _ref7[1];\n return {\n activeDate: (party === null || party === void 0 ? void 0 : party.activeDate) || null,\n partyCode: (party === null || party === void 0 ? void 0 : party.code) || null,\n code: (party === null || party === void 0 || (_party$identification = party.identification) === null || _party$identification === void 0 ? void 0 : _party$identification.value) || null,\n firstName: firstNamePart || null,\n lastName: lastNamePart || null,\n identifications: {\n values: [{\n \"default\": true,\n type: {\n code: \"\",\n name: \"\"\n },\n value: (party === null || party === void 0 || (_party$identification2 = party.identification) === null || _party$identification2 === void 0 ? void 0 : _party$identification2.value) || null\n }]\n },\n birthDate: party === null || party === void 0 ? void 0 : party.birthDate,\n insuredCode: party === null || party === void 0 ? void 0 : party.insuredCode\n };\n })\n };\n return objectMapped;\n};\nvar getCoverages = function getCoverages(p) {\n var _p$coverages;\n var objectMapped = {\n coverages: (_p$coverages = p.coverages) === null || _p$coverages === void 0 ? void 0 : _p$coverages.map(function (c) {\n var _c$coverage, _c$coverage2, _c$coverage3;\n return {\n calculatorTypes: [],\n active: c.active,\n coverage: {\n code: (_c$coverage = c.coverage) === null || _c$coverage === void 0 ? void 0 : _c$coverage.code,\n name: (_c$coverage2 = c.coverage) === null || _c$coverage2 === void 0 ? void 0 : _c$coverage2.description,\n description: (_c$coverage3 = c.coverage) === null || _c$coverage3 === void 0 ? void 0 : _c$coverage3.name\n },\n coverageValues: c.coverageValues,\n type: c.type,\n deductibles: null,\n requiredDeductible: null,\n taxPlan: null,\n wordings: []\n };\n })\n };\n return objectMapped;\n};\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/party/index.js?");
120
+
121
+ /***/ }),
122
+
123
+ /***/ "./src/mapper/modules/policy/index.js":
124
+ /*!********************************************!*\
125
+ !*** ./src/mapper/modules/policy/index.js ***!
126
+ \********************************************/
127
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
128
+
129
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getEndorsements_CNP: () => (/* binding */ getEndorsements_CNP),\n/* harmony export */ getEndorsements_Request: () => (/* binding */ getEndorsements_Request),\n/* harmony export */ getInsureds_CNP: () => (/* binding */ getInsureds_CNP),\n/* harmony export */ getInsureds_CNP_Request: () => (/* binding */ getInsureds_CNP_Request),\n/* harmony export */ getPolicies_CNP: () => (/* binding */ getPolicies_CNP),\n/* harmony export */ getPolicies_CNP_Request: () => (/* binding */ getPolicies_CNP_Request),\n/* harmony export */ getPolicyCollection: () => (/* binding */ getPolicyCollection),\n/* harmony export */ getPolicyCollection_Request: () => (/* binding */ getPolicyCollection_Request),\n/* harmony export */ getPolicyCollectiveDetail_CNP: () => (/* binding */ getPolicyCollectiveDetail_CNP),\n/* harmony export */ getPolicyCollectiveDetail_Request: () => (/* binding */ getPolicyCollectiveDetail_Request),\n/* harmony export */ getPolicyDetail_CNP: () => (/* binding */ getPolicyDetail_CNP),\n/* harmony export */ getPolicyDetail_Request: () => (/* binding */ getPolicyDetail_Request),\n/* harmony export */ getPolicyIndividualDetail_Request: () => (/* binding */ getPolicyIndividualDetail_Request),\n/* harmony export */ postInsureds_CNP: () => (/* binding */ postInsureds_CNP)\n/* harmony export */ });\n/* harmony import */ var dayjs__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! dayjs */ \"dayjs\");\n/* harmony import */ var dayjs__WEBPACK_IMPORTED_MODULE_0___default = /*#__PURE__*/__webpack_require__.n(dayjs__WEBPACK_IMPORTED_MODULE_0__);\n/* harmony import */ var dayjs_plugin_customParseFormat__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! dayjs/plugin/customParseFormat */ \"dayjs/plugin/customParseFormat\");\n/* harmony import */ var dayjs_plugin_customParseFormat__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(dayjs_plugin_customParseFormat__WEBPACK_IMPORTED_MODULE_1__);\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\n\ndayjs__WEBPACK_IMPORTED_MODULE_0___default().extend((dayjs_plugin_customParseFormat__WEBPACK_IMPORTED_MODULE_1___default()));\nvar parseSafeDate = function parseSafeDate(dateString) {\n if (!dateString) return null;\n try {\n // Parsear explícitamente con el formato DD/MM/YYYY\n // El tercer parámetro 'true' activa el modo strict\n var parsed = dayjs__WEBPACK_IMPORTED_MODULE_0___default()(dateString, 'DD/MM/YYYY', true);\n\n // Verificar si la fecha es válida\n if (!parsed.isValid()) {\n console.warn(\"Invalid date format: \".concat(dateString));\n return null;\n }\n return parsed.toISOString();\n } catch (error) {\n console.error(\"Error parsing date: \".concat(dateString), error);\n return null;\n }\n};\nvar getInsureds_CNP = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(response) {\n var _response$insureds, _response$insureds2, _response$insureds3;\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n objectMapped = {\n total: (response === null || response === void 0 || (_response$insureds = response.insureds) === null || _response$insureds === void 0 ? void 0 : _response$insureds.length) || 0,\n totalActive: null,\n values: (response === null || response === void 0 || (_response$insureds2 = response.insureds) === null || _response$insureds2 === void 0 ? void 0 : _response$insureds2.length) > 0 ? response === null || response === void 0 || (_response$insureds3 = response.insureds) === null || _response$insureds3 === void 0 ? void 0 : _response$insureds3.map(function (i) {\n var _i$status, _i$status2;\n return {\n code: i.code,\n number: i.code,\n firstName: i.firstName || i.name,\n lastName: i.lastName,\n type: {\n code: i.role.code === \"T\" ? \"OWNER\" : \"ADHERENT\",\n name: i.role.code === \"T\" ? \"Titular\" : \"Adherente\"\n },\n status: {\n code: ((_i$status = i.status) === null || _i$status === void 0 ? void 0 : _i$status.code) || \"-\",\n name: ((_i$status2 = i.status) === null || _i$status2 === void 0 ? void 0 : _i$status2.name) || \"-\"\n },\n insuredAmount: i.insuredAmount,\n inclusionDate: i.entranceDate,\n exclusionDate: i.cancellationDate,\n identification: {\n value: i.identification.number,\n type: {\n name: i.identification.type.name,\n code: i.identification.type.code\n }\n }\n };\n }) : []\n };\n return _context.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n return function getInsureds_CNP(_x) {\n return _ref.apply(this, arguments);\n };\n}();\nvar getInsureds_CNP_Request = function getInsureds_CNP_Request(inputParams) {\n return {\n code: inputParams.number || undefined,\n name: inputParams.firstName || undefined\n };\n};\nvar postInsureds_CNP = function postInsureds_CNP(payload) {\n var objectMapped = {\n salary: typeof payload.salary === 'string' ? payload.salary : String(payload.salary),\n identification: typeof payload.identification === 'string' ? payload.identification : String(payload.identification)\n };\n return objectMapped;\n};\nvar getEndorsements_CNP = /*#__PURE__*/function () {\n var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee2$(_context2) {\n while (1) switch (_context2.prev = _context2.next) {\n case 0:\n objectMapped = {\n values: response.endorsements.map(function (e) {\n return {\n activeDate: e.dateFrom ? parseSafeDate(e.dateFrom) : null,\n number: e.number,\n type: {\n code: e.detail,\n name: e.detail,\n group: {}\n },\n validityFrom: e.dateFrom ? parseSafeDate(e.dateFrom) : null,\n validityTo: e.dateTo ? parseSafeDate(e.dateTo) : null\n };\n }),\n total: response.endorsements.length\n };\n return _context2.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context2.stop();\n }\n }, _callee2);\n }));\n return function getEndorsements_CNP(_x2) {\n return _ref2.apply(this, arguments);\n };\n}();\nvar getEndorsements_Request = function getEndorsements_Request(inputParams) {\n return {};\n};\nvar getPolicies_CNP = /*#__PURE__*/function () {\n var _ref3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee3$(_context3) {\n while (1) switch (_context3.prev = _context3.next) {\n case 0:\n if (!(!(response !== null && response !== void 0 && response.policies) || response.policies.length === 0)) {\n _context3.next = 2;\n break;\n }\n return _context3.abrupt(\"return\", {\n values: [],\n total: 0\n });\n case 2:\n objectMapped = {\n values: response.policies.map(function (p) {\n var _p$holder, _p$holder2, _p$holder3, _p$holder4, _p$holder5, _p$product, _p$product2, _p$section, _p$section2, _p$status;\n return {\n number: p.number,\n validityFrom: parseSafeDate(p.issueDate),\n validityTo: \"N/A\",\n ingress: parseSafeDate(p.issueDate),\n holder: {\n name: ((_p$holder = p.holder) === null || _p$holder === void 0 ? void 0 : _p$holder.name) || ((_p$holder2 = p.holder) === null || _p$holder2 === void 0 ? void 0 : _p$holder2.firstName),\n identifications: {\n values: [{\n value: ((_p$holder3 = p.holder) === null || _p$holder3 === void 0 || (_p$holder3 = _p$holder3.identification) === null || _p$holder3 === void 0 ? void 0 : _p$holder3.number) || null,\n type: {\n name: ((_p$holder4 = p.holder) === null || _p$holder4 === void 0 || (_p$holder4 = _p$holder4.identification) === null || _p$holder4 === void 0 || (_p$holder4 = _p$holder4.type) === null || _p$holder4 === void 0 ? void 0 : _p$holder4.name) || null,\n code: ((_p$holder5 = p.holder) === null || _p$holder5 === void 0 || (_p$holder5 = _p$holder5.identification) === null || _p$holder5 === void 0 || (_p$holder5 = _p$holder5.type) === null || _p$holder5 === void 0 ? void 0 : _p$holder5.code) || null\n },\n \"default\": true\n }]\n }\n },\n code: p.number,\n alias: \"N/A\",\n product: {\n code: ((_p$product = p.product) === null || _p$product === void 0 || (_p$product = _p$product.code) === null || _p$product === void 0 ? void 0 : _p$product.toString()) || null,\n name: ((_p$product2 = p.product) === null || _p$product2 === void 0 ? void 0 : _p$product2.name) || null,\n subsection: {\n name: \"N/A\",\n code: \"N/A\",\n section: {\n name: ((_p$section = p.section) === null || _p$section === void 0 ? void 0 : _p$section.name) || null,\n code: ((_p$section2 = p.section) === null || _p$section2 === void 0 ? void 0 : _p$section2.code) || null\n }\n }\n },\n process: {\n name: ((_p$status = p.status) === null || _p$status === void 0 ? void 0 : _p$status.name) || null,\n code: \"N/A\"\n }\n };\n }),\n total: response.totalRecord || 0\n };\n return _context3.abrupt(\"return\", objectMapped);\n case 4:\n case \"end\":\n return _context3.stop();\n }\n }, _callee3);\n }));\n return function getPolicies_CNP(_x3) {\n return _ref3.apply(this, arguments);\n };\n}();\nvar getPolicies_CNP_Request = function getPolicies_CNP_Request(inputParams) {\n return {\n sort: \"TomadorCodigo\",\n orderType: \"desc\",\n pageNumber: inputParams.page || 1,\n pageSize: inputParams.pageSize || 10,\n allPolicies: null,\n policyNumber: inputParams.number,\n holderIdentification: inputParams.holderPartyCode,\n requestNumber: inputParams.requestNumber\n };\n};\nvar getPolicyDetail_CNP = /*#__PURE__*/function () {\n var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(data) {\n var _data$holder$identifi, _data$holder$identifi2, _data$insured, _data$insured2, _data$insured3, _data$insured4;\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee4$(_context4) {\n while (1) switch (_context4.prev = _context4.next) {\n case 0:\n objectMapped = {\n policyData: {\n alias: null,\n creationDate: data.insured.policyDateFrom,\n currency: data === null || data === void 0 ? void 0 : data.currency,\n number: data.number,\n process: data.status,\n renewable: null,\n validityy: {\n dateFrom: data === null || data === void 0 ? void 0 : data.vigencyDateFrom,\n dateTo: data === null || data === void 0 ? void 0 : data.vigencyDateTo\n }\n },\n roleData: {\n holder: {\n identification: {\n type: data === null || data === void 0 ? void 0 : data.holder.identification.type,\n value: data === null || data === void 0 || (_data$holder$identifi = data.holder.identification) === null || _data$holder$identifi === void 0 ? void 0 : _data$holder$identifi.number\n },\n name: data.holder.name,\n partyCode: data.holder.code || data.holder.id,\n partyType: null\n },\n contacts: [{\n identification: {\n type: data === null || data === void 0 ? void 0 : data.holder.identification.type,\n value: data === null || data === void 0 || (_data$holder$identifi2 = data.holder.identification) === null || _data$holder$identifi2 === void 0 ? void 0 : _data$holder$identifi2.number\n },\n name: data.holder.name,\n partyCode: data.holder.code || data.holder.id,\n partyType: null\n }]\n },\n collectionData: {\n paymentMethodData: {\n simpleMethodData: {\n number: data.paymentMethod.number,\n type: data.paymentMethod.type\n }\n },\n paymentFrequency: data.paymentMethod.periodicity\n },\n commercialStructureData: {\n data: {},\n intermediaries: {\n values: [{\n code: data.intermediary.id,\n name: data.intermediary.name,\n role: null,\n status: null\n }]\n }\n },\n productData: {\n number: data.product.code || data.product.id,\n name: data.product.name,\n status: {},\n subsection: {\n name: null,\n code: null,\n section: data.section\n }\n },\n coverageData: {\n coverages: data === null || data === void 0 || (_data$insured = data.insured) === null || _data$insured === void 0 ? void 0 : _data$insured.coverages.map(function (cv) {\n return {\n ageType: null,\n deductible: null,\n coverage: {\n calculatorType: null,\n code: null,\n name: cv.name,\n type: cv.type\n },\n values: [{\n minValue: cv.amount,\n maxValue: cv.amount,\n type: {\n code: \"INSURED_AMOUNT\",\n name: \"Suma aseguradas\"\n }\n }]\n };\n })\n },\n expenseData: {\n values: []\n },\n wordingData: {\n wordings: []\n },\n termData: {\n values: []\n },\n documentationData: {\n files: [],\n comments: \"\"\n },\n endorsementData: {\n number: data === null || data === void 0 ? void 0 : data.endorsementNumber\n },\n insurableData: {\n minimumQuantityInsured: 0,\n estimatedDeadline: (data === null || data === void 0 || (_data$insured2 = data.insured) === null || _data$insured2 === void 0 ? void 0 : _data$insured2.entranceDate) || null,\n minimumAge: 0,\n maximumAge: 0,\n maximumQuantityInsuredByEvent: 0,\n maximumAmountToIndemnify: 0,\n insurables: data !== null && data !== void 0 && data.insured ? [{\n type: {\n name: (data === null || data === void 0 || (_data$insured3 = data.insured) === null || _data$insured3 === void 0 || (_data$insured3 = _data$insured3.type) === null || _data$insured3 === void 0 ? void 0 : _data$insured3.name) || null,\n code: (data === null || data === void 0 || (_data$insured4 = data.insured) === null || _data$insured4 === void 0 || (_data$insured4 = _data$insured4.type) === null || _data$insured4 === void 0 ? void 0 : _data$insured4.code) || null\n },\n wording: null,\n minimumEntryAge: 0,\n maximumEntryAge: 0,\n endingAgePrincipalCoverage: 0,\n endingAgeAditionalCoverage: 0\n }] : null\n },\n savings: {\n accountBalance: (data === null || data === void 0 ? void 0 : data.accountBalance) || null,\n annualPremium: (data === null || data === void 0 ? void 0 : data.annualPremium) || null,\n premium: (data === null || data === void 0 ? void 0 : data.premium) || null,\n prize: (data === null || data === void 0 ? void 0 : data.prize) || null,\n simpleEndorsementPremium: (data === null || data === void 0 ? void 0 : data.simpleEndorsementPremium) || null\n },\n salesAgent: (data === null || data === void 0 ? void 0 : data.salesAgent) || null,\n salesBranch: (data === null || data === void 0 ? void 0 : data.salesBranch) || null\n };\n return _context4.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context4.stop();\n }\n }, _callee4);\n }));\n return function getPolicyDetail_CNP(_x4) {\n return _ref4.apply(this, arguments);\n };\n}();\nvar getPolicyCollection = /*#__PURE__*/function () {\n var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(data) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee5$(_context5) {\n while (1) switch (_context5.prev = _context5.next) {\n case 0:\n objectMapped = {\n billingForm: {},\n holderDistribution: null,\n insuredDistribution: null,\n paymentFrecuency: data.paymentMethod.periodicity,\n paymentMethodData: {\n simpleMethodData: {\n number: data.paymentMethod.number,\n method: data.paymentMethod.type\n }\n }\n };\n return _context5.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context5.stop();\n }\n }, _callee5);\n }));\n return function getPolicyCollection(_x5) {\n return _ref5.apply(this, arguments);\n };\n}();\nvar getPolicyCollectiveDetail_CNP = /*#__PURE__*/function () {\n var _ref6 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(response) {\n var _response$currency, _response$currency2, _response$currency3, _response$currency4, _response$currency5, _response$status, _response$holder, _response$holder2, _response$holder3, _response$holder4, _response$holder5, _response$holder6, _response$holder7, _response$paymentMeth, _response$paymentMeth2, _response$currency6, _response$paymentMeth3, _response$paymentMeth4, _response$currency7, _response$paymentMeth5, _response$intermediar, _response$intermediar2, _response$product, _response$product2, _response$section, _response$section2, _response$status2, _response$insured, _response$insured2, _response$insured3, _response$insured4;\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee6$(_context6) {\n while (1) switch (_context6.prev = _context6.next) {\n case 0:\n objectMapped = {\n policyData: {\n number: (response === null || response === void 0 ? void 0 : response.number) || null,\n alias: \"N/A\",\n currency: {\n name: (response === null || response === void 0 || (_response$currency = response.currency) === null || _response$currency === void 0 ? void 0 : _response$currency.name) || null,\n code: (response === null || response === void 0 || (_response$currency2 = response.currency) === null || _response$currency2 === void 0 ? void 0 : _response$currency2.code) || null,\n mnemonic: \"N/A\",\n symbol: (response === null || response === void 0 || (_response$currency3 = response.currency) === null || _response$currency3 === void 0 ? void 0 : _response$currency3.symbol) || null\n },\n validity: {\n type: {\n name: (response === null || response === void 0 || (_response$currency4 = response.currency) === null || _response$currency4 === void 0 ? void 0 : _response$currency4.name) || null,\n code: (response === null || response === void 0 || (_response$currency5 = response.currency) === null || _response$currency5 === void 0 ? void 0 : _response$currency5.code) || null,\n months: \"N/A\"\n },\n dateFrom: response !== null && response !== void 0 && response.vigencyDateFrom ? parseSafeDate(response.vigencyDateFrom) : null,\n dateTo: response !== null && response !== void 0 && response.vigencyDateTo ? parseSafeDate(response.vigencyDateTo) : null\n },\n creationDate: response !== null && response !== void 0 && response.issueDate ? parseSafeDate(response.issueDate) : null,\n renewable: true,\n process: {\n name: (response === null || response === void 0 || (_response$status = response.status) === null || _response$status === void 0 ? void 0 : _response$status.name) || null,\n code: \"N/A\"\n }\n },\n roleData: {\n holder: {\n partyCode: (response === null || response === void 0 || (_response$holder = response.holder) === null || _response$holder === void 0 ? void 0 : _response$holder.code) || null,\n name: response !== null && response !== void 0 && (_response$holder2 = response.holder) !== null && _response$holder2 !== void 0 && _response$holder2.firstName && response !== null && response !== void 0 && (_response$holder3 = response.holder) !== null && _response$holder3 !== void 0 && _response$holder3.lastName ? \"\".concat(response.holder.firstName, \" \").concat(response.holder.lastName) : (response === null || response === void 0 || (_response$holder4 = response.holder) === null || _response$holder4 === void 0 ? void 0 : _response$holder4.name) || null,\n identification: {\n value: (response === null || response === void 0 || (_response$holder5 = response.holder) === null || _response$holder5 === void 0 || (_response$holder5 = _response$holder5.identification) === null || _response$holder5 === void 0 ? void 0 : _response$holder5.number) || null,\n type: {\n code: (response === null || response === void 0 || (_response$holder6 = response.holder) === null || _response$holder6 === void 0 || (_response$holder6 = _response$holder6.identification) === null || _response$holder6 === void 0 || (_response$holder6 = _response$holder6.type) === null || _response$holder6 === void 0 ? void 0 : _response$holder6.code) || null,\n name: (response === null || response === void 0 || (_response$holder7 = response.holder) === null || _response$holder7 === void 0 || (_response$holder7 = _response$holder7.identification) === null || _response$holder7 === void 0 || (_response$holder7 = _response$holder7.type) === null || _response$holder7 === void 0 ? void 0 : _response$holder7.name) || null\n }\n }\n },\n contacts: [{\n partyCode: \"N/A\",\n name: \"N/A\",\n identification: {\n value: \"N/A\",\n type: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }\n }],\n legalResponsible: {\n partyCode: \"N/A\",\n name: \"N/A\",\n identification: {\n value: \"N/A\",\n type: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }\n }\n },\n collectionData: {\n holderDistribution: 0,\n insuredDistribution: 0,\n paymentFrequency: {\n name: (response === null || response === void 0 || (_response$paymentMeth = response.paymentMethod) === null || _response$paymentMeth === void 0 || (_response$paymentMeth = _response$paymentMeth.periodicity) === null || _response$paymentMeth === void 0 ? void 0 : _response$paymentMeth.name) || null,\n code: \"N/A\"\n },\n paymentMethodData: {\n cashMethodData: (response === null || response === void 0 || (_response$paymentMeth2 = response.paymentMethod) === null || _response$paymentMeth2 === void 0 ? void 0 : _response$paymentMeth2.name) === \"CASH\" ? {\n values: [{\n code: \"N/A\",\n name: (response === null || response === void 0 || (_response$currency6 = response.currency) === null || _response$currency6 === void 0 ? void 0 : _response$currency6.name) || null\n }]\n } : null,\n bankAccountData: (response === null || response === void 0 || (_response$paymentMeth3 = response.paymentMethod) === null || _response$paymentMeth3 === void 0 ? void 0 : _response$paymentMeth3.name) === \"CBU\" ? {\n values: [{\n code: \"BA-1\",\n number: \"1\",\n cbu: (response === null || response === void 0 || (_response$paymentMeth4 = response.paymentMethod) === null || _response$paymentMeth4 === void 0 ? void 0 : _response$paymentMeth4.bankAccountNumber) || null,\n alias: \"N/A\",\n currency: {\n code: \"N/A\",\n name: (response === null || response === void 0 || (_response$currency7 = response.currency) === null || _response$currency7 === void 0 ? void 0 : _response$currency7.name) || null\n },\n bankBranch: {\n name: \"N/A\",\n code: \"N/A\",\n bank: {\n name: \"N/A\",\n code: \"N/A\"\n }\n },\n bankAccountType: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }]\n } : null,\n creditCardData: (response === null || response === void 0 || (_response$paymentMeth5 = response.paymentMethod) === null || _response$paymentMeth5 === void 0 ? void 0 : _response$paymentMeth5.name) === \"CREDIT\" ? {\n values: [{\n code: \"N/A\",\n ownerName: \"N/A\",\n cardType: {\n name: \"N/A\",\n code: \"N/A\"\n },\n cardProvider: {\n name: \"N/A\",\n code: \"N/A\"\n },\n number: \"N/A\",\n securityCode: \"N/A\",\n dateTo: \"N/A\"\n }]\n } : null\n }\n },\n commercialStructureData: {\n data: {\n name: \"N/A\",\n code: \"N/A\",\n version: 0,\n description: \"N/A\",\n status: {\n name: \"N/A\",\n code: \"N/A\"\n }\n },\n intermediaries: {\n values: [{\n code: (response === null || response === void 0 || (_response$intermediar = response.intermediary) === null || _response$intermediar === void 0 || (_response$intermediar = _response$intermediar.code) === null || _response$intermediar === void 0 ? void 0 : _response$intermediar.toString()) || null,\n name: (response === null || response === void 0 || (_response$intermediar2 = response.intermediary) === null || _response$intermediar2 === void 0 ? void 0 : _response$intermediar2.name) || null,\n licence: \"N/A\",\n role: {\n name: \"N/A\",\n code: \"N/A\"\n },\n status: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }]\n }\n },\n productData: {\n name: (response === null || response === void 0 || (_response$product = response.product) === null || _response$product === void 0 ? void 0 : _response$product.name) || null,\n code: (response === null || response === void 0 || (_response$product2 = response.product) === null || _response$product2 === void 0 ? void 0 : _response$product2.code) || null,\n version: 0,\n subsection: {\n name: \"N/A\",\n code: \"N/A\",\n section: {\n name: (response === null || response === void 0 || (_response$section = response.section) === null || _response$section === void 0 ? void 0 : _response$section.name) || null,\n code: (response === null || response === void 0 || (_response$section2 = response.section) === null || _response$section2 === void 0 ? void 0 : _response$section2.code) || null\n }\n },\n status: {\n name: (response === null || response === void 0 || (_response$status2 = response.status) === null || _response$status2 === void 0 ? void 0 : _response$status2.name) || null,\n code: \"N/A\"\n }\n },\n coverageData: {\n coverages: (response === null || response === void 0 || (_response$insured = response.insured) === null || _response$insured === void 0 || (_response$insured = _response$insured.coverages) === null || _response$insured === void 0 ? void 0 : _response$insured.map(function (c) {\n return {\n coverage: {\n name: (c === null || c === void 0 ? void 0 : c.name) || null,\n code: 'N/A',\n calculatorType: {\n name: \"N/A\",\n code: \"N/A\"\n },\n type: {\n name: \"N/A\",\n code: \"N/A\"\n }\n },\n values: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n maxValue: \"N/A\",\n minValue: \"N/A\"\n }],\n mortalityTable: {\n name: \"N/A\",\n code: \"N/A\"\n },\n ageType: {\n name: \"N/A\",\n code: \"N/A\"\n }\n };\n })) || []\n },\n expenseData: {\n values: []\n },\n wordingData: {\n wordings: []\n },\n termData: {\n values: []\n },\n documentationData: {\n files: [],\n comments: \"N/A\"\n },\n endorsementData: {\n number: (response === null || response === void 0 ? void 0 : response.endorsementNumber) || 0,\n validityFrom: \"N/A\",\n validityTo: \"N/A\",\n type: {\n name: \"N/A\",\n code: \"N/A\"\n }\n },\n insurableData: {\n minimumQuantityInsured: 0,\n estimatedDeadline: (response === null || response === void 0 || (_response$insured2 = response.insured) === null || _response$insured2 === void 0 ? void 0 : _response$insured2.entranceDate) || null,\n minimumAge: 0,\n maximumAge: 0,\n maximumQuantityInsuredByEvent: 0,\n maximumAmountToIndemnify: \"N/A\",\n insurables: response !== null && response !== void 0 && response.insured ? [{\n type: {\n name: (response === null || response === void 0 || (_response$insured3 = response.insured) === null || _response$insured3 === void 0 || (_response$insured3 = _response$insured3.type) === null || _response$insured3 === void 0 ? void 0 : _response$insured3.name) || null,\n code: (response === null || response === void 0 || (_response$insured4 = response.insured) === null || _response$insured4 === void 0 || (_response$insured4 = _response$insured4.type) === null || _response$insured4 === void 0 ? void 0 : _response$insured4.code) || null\n },\n wording: \"N/A\",\n minimumEntryAge: 0,\n maximumEntryAge: 0,\n endingAgePrincipalCoverage: 0,\n endingAgeAditionalCoverage: 0\n }] : null\n }\n };\n return _context6.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context6.stop();\n }\n }, _callee6);\n }));\n return function getPolicyCollectiveDetail_CNP(_x6) {\n return _ref6.apply(this, arguments);\n };\n}();\nvar getPolicyDetail_Request = function getPolicyDetail_Request(inputParams) {\n return {};\n};\nvar getPolicyCollection_Request = function getPolicyCollection_Request(inputParams) {\n return {};\n};\nvar getPolicyCollectiveDetail_Request = function getPolicyCollectiveDetail_Request(inputParams) {\n return {};\n};\nvar getPolicyIndividualDetail_Request = function getPolicyIndividualDetail_Request(inputParams) {\n return {};\n};\n\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/policy/index.js?");
130
+
131
+ /***/ }),
132
+
133
+ /***/ "./src/mapper/modules/quotation/index.js":
134
+ /*!***********************************************!*\
135
+ !*** ./src/mapper/modules/quotation/index.js ***!
136
+ \***********************************************/
137
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
138
+
139
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getActivityList: () => (/* binding */ getActivityList),\n/* harmony export */ getPaymentFrecuencies: () => (/* binding */ getPaymentFrecuencies),\n/* harmony export */ getProductParameters: () => (/* binding */ getProductParameters),\n/* harmony export */ getProductsBySubsections: () => (/* binding */ getProductsBySubsections),\n/* harmony export */ getQuotationByCode: () => (/* binding */ getQuotationByCode),\n/* harmony export */ getQuotationByCode_Request: () => (/* binding */ getQuotationByCode_Request),\n/* harmony export */ getQuotationDetail: () => (/* binding */ getQuotationDetail),\n/* harmony export */ getQuotationsList: () => (/* binding */ getQuotationsList),\n/* harmony export */ getQuotations_Request: () => (/* binding */ getQuotations_Request),\n/* harmony export */ quotationStandardPlanCreationMapped: () => (/* binding */ quotationStandardPlanCreationMapped),\n/* harmony export */ quotationVariablePlanCreationMapped: () => (/* binding */ quotationVariablePlanCreationMapped)\n/* harmony export */ });\n/* harmony import */ var _helpers_mappingHelpers__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ../../helpers/mappingHelpers */ \"./src/mapper/helpers/mappingHelpers.js\");\n/* harmony import */ var dayjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! dayjs */ \"dayjs\");\n/* harmony import */ var dayjs__WEBPACK_IMPORTED_MODULE_1___default = /*#__PURE__*/__webpack_require__.n(dayjs__WEBPACK_IMPORTED_MODULE_1__);\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _regeneratorRuntime() { \"use strict\"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return e; }; var t, e = {}, r = Object.prototype, n = r.hasOwnProperty, o = Object.defineProperty || function (t, e, r) { t[e] = r.value; }, i = \"function\" == typeof Symbol ? Symbol : {}, a = i.iterator || \"@@iterator\", c = i.asyncIterator || \"@@asyncIterator\", u = i.toStringTag || \"@@toStringTag\"; function define(t, e, r) { return Object.defineProperty(t, e, { value: r, enumerable: !0, configurable: !0, writable: !0 }), t[e]; } try { define({}, \"\"); } catch (t) { define = function define(t, e, r) { return t[e] = r; }; } function wrap(t, e, r, n) { var i = e && e.prototype instanceof Generator ? e : Generator, a = Object.create(i.prototype), c = new Context(n || []); return o(a, \"_invoke\", { value: makeInvokeMethod(t, r, c) }), a; } function tryCatch(t, e, r) { try { return { type: \"normal\", arg: t.call(e, r) }; } catch (t) { return { type: \"throw\", arg: t }; } } e.wrap = wrap; var h = \"suspendedStart\", l = \"suspendedYield\", f = \"executing\", s = \"completed\", y = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var p = {}; define(p, a, function () { return this; }); var d = Object.getPrototypeOf, v = d && d(d(values([]))); v && v !== r && n.call(v, a) && (p = v); var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p); function defineIteratorMethods(t) { [\"next\", \"throw\", \"return\"].forEach(function (e) { define(t, e, function (t) { return this._invoke(e, t); }); }); } function AsyncIterator(t, e) { function invoke(r, o, i, a) { var c = tryCatch(t[r], t, o); if (\"throw\" !== c.type) { var u = c.arg, h = u.value; return h && \"object\" == _typeof(h) && n.call(h, \"__await\") ? e.resolve(h.__await).then(function (t) { invoke(\"next\", t, i, a); }, function (t) { invoke(\"throw\", t, i, a); }) : e.resolve(h).then(function (t) { u.value = t, i(u); }, function (t) { return invoke(\"throw\", t, i, a); }); } a(c.arg); } var r; o(this, \"_invoke\", { value: function value(t, n) { function callInvokeWithMethodAndArg() { return new e(function (e, r) { invoke(t, n, e, r); }); } return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(e, r, n) { var o = h; return function (i, a) { if (o === f) throw Error(\"Generator is already running\"); if (o === s) { if (\"throw\" === i) throw a; return { value: t, done: !0 }; } for (n.method = i, n.arg = a;;) { var c = n.delegate; if (c) { var u = maybeInvokeDelegate(c, n); if (u) { if (u === y) continue; return u; } } if (\"next\" === n.method) n.sent = n._sent = n.arg;else if (\"throw\" === n.method) { if (o === h) throw o = s, n.arg; n.dispatchException(n.arg); } else \"return\" === n.method && n.abrupt(\"return\", n.arg); o = f; var p = tryCatch(e, r, n); if (\"normal\" === p.type) { if (o = n.done ? s : l, p.arg === y) continue; return { value: p.arg, done: n.done }; } \"throw\" === p.type && (o = s, n.method = \"throw\", n.arg = p.arg); } }; } function maybeInvokeDelegate(e, r) { var n = r.method, o = e.iterator[n]; if (o === t) return r.delegate = null, \"throw\" === n && e.iterator[\"return\"] && (r.method = \"return\", r.arg = t, maybeInvokeDelegate(e, r), \"throw\" === r.method) || \"return\" !== n && (r.method = \"throw\", r.arg = new TypeError(\"The iterator does not provide a '\" + n + \"' method\")), y; var i = tryCatch(o, e.iterator, r.arg); if (\"throw\" === i.type) return r.method = \"throw\", r.arg = i.arg, r.delegate = null, y; var a = i.arg; return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, \"return\" !== r.method && (r.method = \"next\", r.arg = t), r.delegate = null, y) : a : (r.method = \"throw\", r.arg = new TypeError(\"iterator result is not an object\"), r.delegate = null, y); } function pushTryEntry(t) { var e = { tryLoc: t[0] }; 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e); } function resetTryEntry(t) { var e = t.completion || {}; e.type = \"normal\", delete e.arg, t.completion = e; } function Context(t) { this.tryEntries = [{ tryLoc: \"root\" }], t.forEach(pushTryEntry, this), this.reset(!0); } function values(e) { if (e || \"\" === e) { var r = e[a]; if (r) return r.call(e); if (\"function\" == typeof e.next) return e; if (!isNaN(e.length)) { var o = -1, i = function next() { for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next; return next.value = t, next.done = !0, next; }; return i.next = i; } } throw new TypeError(_typeof(e) + \" is not iterable\"); } return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, \"constructor\", { value: GeneratorFunctionPrototype, configurable: !0 }), o(GeneratorFunctionPrototype, \"constructor\", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, \"GeneratorFunction\"), e.isGeneratorFunction = function (t) { var e = \"function\" == typeof t && t.constructor; return !!e && (e === GeneratorFunction || \"GeneratorFunction\" === (e.displayName || e.name)); }, e.mark = function (t) { return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, \"GeneratorFunction\")), t.prototype = Object.create(g), t; }, e.awrap = function (t) { return { __await: t }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () { return this; }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) { void 0 === i && (i = Promise); var a = new AsyncIterator(wrap(t, r, n, o), i); return e.isGeneratorFunction(r) ? a : a.next().then(function (t) { return t.done ? t.value : a.next(); }); }, defineIteratorMethods(g), define(g, u, \"Generator\"), define(g, a, function () { return this; }), define(g, \"toString\", function () { return \"[object Generator]\"; }), e.keys = function (t) { var e = Object(t), r = []; for (var n in e) r.push(n); return r.reverse(), function next() { for (; r.length;) { var t = r.pop(); if (t in e) return next.value = t, next.done = !1, next; } return next.done = !0, next; }; }, e.values = values, Context.prototype = { constructor: Context, reset: function reset(e) { if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = \"next\", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) \"t\" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t); }, stop: function stop() { this.done = !0; var t = this.tryEntries[0].completion; if (\"throw\" === t.type) throw t.arg; return this.rval; }, dispatchException: function dispatchException(e) { if (this.done) throw e; var r = this; function handle(n, o) { return a.type = \"throw\", a.arg = e, r.next = n, o && (r.method = \"next\", r.arg = t), !!o; } for (var o = this.tryEntries.length - 1; o >= 0; --o) { var i = this.tryEntries[o], a = i.completion; if (\"root\" === i.tryLoc) return handle(\"end\"); if (i.tryLoc <= this.prev) { var c = n.call(i, \"catchLoc\"), u = n.call(i, \"finallyLoc\"); if (c && u) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } else if (c) { if (this.prev < i.catchLoc) return handle(i.catchLoc, !0); } else { if (!u) throw Error(\"try statement without catch or finally\"); if (this.prev < i.finallyLoc) return handle(i.finallyLoc); } } } }, abrupt: function abrupt(t, e) { for (var r = this.tryEntries.length - 1; r >= 0; --r) { var o = this.tryEntries[r]; if (o.tryLoc <= this.prev && n.call(o, \"finallyLoc\") && this.prev < o.finallyLoc) { var i = o; break; } } i && (\"break\" === t || \"continue\" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null); var a = i ? i.completion : {}; return a.type = t, a.arg = e, i ? (this.method = \"next\", this.next = i.finallyLoc, y) : this.complete(a); }, complete: function complete(t, e) { if (\"throw\" === t.type) throw t.arg; return \"break\" === t.type || \"continue\" === t.type ? this.next = t.arg : \"return\" === t.type ? (this.rval = this.arg = t.arg, this.method = \"return\", this.next = \"end\") : \"normal\" === t.type && e && (this.next = e), y; }, finish: function finish(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y; } }, \"catch\": function _catch(t) { for (var e = this.tryEntries.length - 1; e >= 0; --e) { var r = this.tryEntries[e]; if (r.tryLoc === t) { var n = r.completion; if (\"throw\" === n.type) { var o = n.arg; resetTryEntry(r); } return o; } } throw Error(\"illegal catch attempt\"); }, delegateYield: function delegateYield(e, r, n) { return this.delegate = { iterator: values(e), resultName: r, nextLoc: n }, \"next\" === this.method && (this.arg = t), y; } }, e; }\nfunction asyncGeneratorStep(n, t, e, r, o, a, c) { try { var i = n[a](c), u = i.value; } catch (n) { return void e(n); } i.done ? t(u) : Promise.resolve(u).then(r, o); }\nfunction _asyncToGenerator(n) { return function () { var t = this, e = arguments; return new Promise(function (r, o) { var a = n.apply(t, e); function _next(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"next\", n); } function _throw(n) { asyncGeneratorStep(a, r, o, _next, _throw, \"throw\", n); } _next(void 0); }); }; }\n\n\nvar normalizeDateToYYYYMMDD = function normalizeDateToYYYYMMDD(date) {\n if (!date) return null;\n var formats = ['DD/MM/YYYY', 'YYYY/MM/DD'];\n var parsed = dayjs__WEBPACK_IMPORTED_MODULE_1___default()(date, formats, true);\n return parsed.isValid() ? parsed.format('YYYY/MM/DD') : null;\n};\nvar getQuotationsList = /*#__PURE__*/function () {\n var _ref = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee(response) {\n var quotations, total;\n return _regeneratorRuntime().wrap(function _callee$(_context) {\n while (1) switch (_context.prev = _context.next) {\n case 0:\n quotations = Array.isArray(response === null || response === void 0 ? void 0 : response.quotations) ? response.quotations.map(function (q) {\n var _q$paymentFrequency, _q$paymentFrequency2, _q$product, _q$product2, _q$product3, _q$product4, _q$product5, _q$product6, _q$product7, _q$status, _q$status2;\n return {\n code: q.code || null,\n email: q.email || null,\n creationDate: normalizeDateToYYYYMMDD(q.creationDate),\n expirationDate: normalizeDateToYYYYMMDD(q.expirationDate),\n number: q.number || null,\n paymentFrequency: {\n name: ((_q$paymentFrequency = q.paymentFrequency) === null || _q$paymentFrequency === void 0 ? void 0 : _q$paymentFrequency.name) || null,\n code: ((_q$paymentFrequency2 = q.paymentFrequency) === null || _q$paymentFrequency2 === void 0 ? void 0 : _q$paymentFrequency2.code) || null\n },\n product: {\n code: ((_q$product = q.product) === null || _q$product === void 0 || (_q$product = _q$product.code) === null || _q$product === void 0 ? void 0 : _q$product.toString()) || null,\n name: ((_q$product2 = q.product) === null || _q$product2 === void 0 ? void 0 : _q$product2.name) || null,\n subsection: {\n code: ((_q$product3 = q.product) === null || _q$product3 === void 0 || (_q$product3 = _q$product3.subsection) === null || _q$product3 === void 0 ? void 0 : _q$product3.code) || null,\n name: ((_q$product4 = q.product) === null || _q$product4 === void 0 || (_q$product4 = _q$product4.subsection) === null || _q$product4 === void 0 ? void 0 : _q$product4.name) || null,\n section: {\n code: ((_q$product5 = q.product) === null || _q$product5 === void 0 || (_q$product5 = _q$product5.subsection) === null || _q$product5 === void 0 || (_q$product5 = _q$product5.section) === null || _q$product5 === void 0 ? void 0 : _q$product5.code) || null,\n name: ((_q$product6 = q.product) === null || _q$product6 === void 0 || (_q$product6 = _q$product6.subsection) === null || _q$product6 === void 0 || (_q$product6 = _q$product6.section) === null || _q$product6 === void 0 ? void 0 : _q$product6.name) || null\n }\n },\n version: ((_q$product7 = q.product) === null || _q$product7 === void 0 ? void 0 : _q$product7.version) || 0\n },\n status: {\n code: ((_q$status = q.status) === null || _q$status === void 0 ? void 0 : _q$status.code) || null,\n name: ((_q$status2 = q.status) === null || _q$status2 === void 0 ? void 0 : _q$status2.name) || null\n }\n };\n }) : [];\n total = response !== null && response !== void 0 && response.total ? response.total : 0;\n return _context.abrupt(\"return\", {\n quotations: quotations,\n total: total\n });\n case 3:\n case \"end\":\n return _context.stop();\n }\n }, _callee);\n }));\n return function getQuotationsList(_x) {\n return _ref.apply(this, arguments);\n };\n}();\nvar getQuotationDetail = /*#__PURE__*/function () {\n var _ref2 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee2(res) {\n var _res$intermediary, _res$intermediary2, _res$intermediary3, _res$paymentFrequency, _res$paymentFrequency2, _res$paymentFrequency3, _res$product, _res$product2, _res$product3, _res$product4, _res$product5, _res$product6, _res$product7, _res$status, _res$status2, _res$values, _res$values2;\n var quotation;\n return _regeneratorRuntime().wrap(function _callee2$(_context2) {\n while (1) switch (_context2.prev = _context2.next) {\n case 0:\n quotation = {\n areaCode: (res === null || res === void 0 ? void 0 : res.areaCode) || null,\n code: (res === null || res === void 0 ? void 0 : res.code) || null,\n commercialStructure: {\n data: {\n code: null,\n description: null,\n name: null,\n status: {\n code: null,\n name: null\n },\n version: 0\n },\n intermediaries: {\n values: []\n }\n },\n creationDate: (res === null || res === void 0 ? void 0 : res.creationDate) || null,\n email: (res === null || res === void 0 ? void 0 : res.email) || null,\n intermediary: {\n code: (res === null || res === void 0 || (_res$intermediary = res.intermediary) === null || _res$intermediary === void 0 ? void 0 : _res$intermediary.code) || null,\n group: {\n code: null,\n name: null\n },\n licence: (res === null || res === void 0 || (_res$intermediary2 = res.intermediary) === null || _res$intermediary2 === void 0 ? void 0 : _res$intermediary2.licence) || null,\n name: (res === null || res === void 0 || (_res$intermediary3 = res.intermediary) === null || _res$intermediary3 === void 0 ? void 0 : _res$intermediary3.name) || null,\n roles: [{\n code: null,\n name: null\n }],\n status: {\n code: null,\n name: null\n }\n },\n number: (res === null || res === void 0 ? void 0 : res.number) || null,\n paymentFrequency: {\n code: (res === null || res === void 0 || (_res$paymentFrequency = res.paymentFrequency) === null || _res$paymentFrequency === void 0 ? void 0 : _res$paymentFrequency.code) || null,\n months: (res === null || res === void 0 || (_res$paymentFrequency2 = res.paymentFrequency) === null || _res$paymentFrequency2 === void 0 ? void 0 : _res$paymentFrequency2.months) || null,\n name: (res === null || res === void 0 || (_res$paymentFrequency3 = res.paymentFrequency) === null || _res$paymentFrequency3 === void 0 ? void 0 : _res$paymentFrequency3.name) || null\n },\n phone: (res === null || res === void 0 ? void 0 : res.phone) || null,\n product: {\n code: (res === null || res === void 0 || (_res$product = res.product) === null || _res$product === void 0 ? void 0 : _res$product.code) || null,\n currency: {\n code: null,\n mnemonic: null,\n name: null,\n symbol: null\n },\n name: (res === null || res === void 0 || (_res$product2 = res.product) === null || _res$product2 === void 0 ? void 0 : _res$product2.name) || null,\n status: {\n code: null,\n name: null\n },\n subsection: {\n code: (res === null || res === void 0 || (_res$product3 = res.product) === null || _res$product3 === void 0 || (_res$product3 = _res$product3.subsection) === null || _res$product3 === void 0 ? void 0 : _res$product3.code) || null,\n name: (res === null || res === void 0 || (_res$product4 = res.product) === null || _res$product4 === void 0 || (_res$product4 = _res$product4.subsection) === null || _res$product4 === void 0 ? void 0 : _res$product4.name) || null,\n section: {\n category: null,\n code: (res === null || res === void 0 || (_res$product5 = res.product) === null || _res$product5 === void 0 || (_res$product5 = _res$product5.subsection) === null || _res$product5 === void 0 || (_res$product5 = _res$product5.section) === null || _res$product5 === void 0 ? void 0 : _res$product5.code) || null,\n name: (res === null || res === void 0 || (_res$product6 = res.product) === null || _res$product6 === void 0 || (_res$product6 = _res$product6.subsection) === null || _res$product6 === void 0 || (_res$product6 = _res$product6.section) === null || _res$product6 === void 0 ? void 0 : _res$product6.name) || null,\n type: null\n }\n },\n version: (res === null || res === void 0 || (_res$product7 = res.product) === null || _res$product7 === void 0 ? void 0 : _res$product7.version) || 0\n },\n productSegment: null,\n status: {\n code: (res === null || res === void 0 || (_res$status = res.status) === null || _res$status === void 0 ? void 0 : _res$status.code) || null,\n name: (res === null || res === void 0 || (_res$status2 = res.status) === null || _res$status2 === void 0 ? void 0 : _res$status2.name) || null\n },\n validity: {\n code: null,\n months: 0,\n name: null\n },\n values: {\n commercialAgreement: {\n code: null,\n intermediaries: []\n },\n expenses: [],\n groupedEconomicValues: (res === null || res === void 0 || (_res$values = res.values) === null || _res$values === void 0 || (_res$values = _res$values.groupedEconomicValues) === null || _res$values === void 0 ? void 0 : _res$values.map(function (e) {\n var _e$type, _e$type2;\n return {\n type: {\n code: (e === null || e === void 0 || (_e$type = e.type) === null || _e$type === void 0 ? void 0 : _e$type.code) || null,\n name: (e === null || e === void 0 || (_e$type2 = e.type) === null || _e$type2 === void 0 ? void 0 : _e$type2.name) || null\n },\n value: (e === null || e === void 0 ? void 0 : e.value) || null\n };\n })) || [],\n risks: (res === null || res === void 0 || (_res$values2 = res.values) === null || _res$values2 === void 0 || (_res$values2 = _res$values2.risks) === null || _res$values2 === void 0 ? void 0 : _res$values2.map(function (risk) {\n var _risk$coverages, _risk$data, _risk$data2, _risk$data3, _risk$data4, _risk$data5, _risk$data6, _risk$data7, _risk$data$identifica, _risk$data8, _risk$data$firstName, _risk$data9, _risk$data$lastName, _risk$data10, _risk$data$spouse, _risk$data11, _risk$data12, _risk$data13, _risk$data14, _risk$data15, _risk$data16;\n return {\n adherents: [],\n code: (risk === null || risk === void 0 ? void 0 : risk.code) || null,\n coverages: (risk === null || risk === void 0 || (_risk$coverages = risk.coverages) === null || _risk$coverages === void 0 ? void 0 : _risk$coverages.map(function (cv) {\n var _cv$coverageValues;\n return {\n code: (cv === null || cv === void 0 ? void 0 : cv.code) || null,\n coverageValues: (cv === null || cv === void 0 || (_cv$coverageValues = cv.coverageValues) === null || _cv$coverageValues === void 0 ? void 0 : _cv$coverageValues.map(function (c) {\n var _c$type, _c$type2;\n return {\n type: {\n code: (c === null || c === void 0 || (_c$type = c.type) === null || _c$type === void 0 ? void 0 : _c$type.code) || null,\n name: (c === null || c === void 0 || (_c$type2 = c.type) === null || _c$type2 === void 0 ? void 0 : _c$type2.name) || null\n },\n value: (c === null || c === void 0 ? void 0 : c.value) || null\n };\n })) || [],\n deductible: null,\n economicValues: [{\n type: {\n code: null,\n name: null\n },\n value: 0\n }],\n name: (cv === null || cv === void 0 ? void 0 : cv.description) || null,\n description: (cv === null || cv === void 0 ? void 0 : cv.name) || null\n };\n })) || [],\n data: {\n city: {\n code: (risk === null || risk === void 0 || (_risk$data = risk.data) === null || _risk$data === void 0 || (_risk$data = _risk$data.city) === null || _risk$data === void 0 ? void 0 : _risk$data.code) || null,\n name: (risk === null || risk === void 0 || (_risk$data2 = risk.data) === null || _risk$data2 === void 0 || (_risk$data2 = _risk$data2.city) === null || _risk$data2 === void 0 ? void 0 : _risk$data2.name) || null,\n province: (risk === null || risk === void 0 || (_risk$data3 = risk.data) === null || _risk$data3 === void 0 || (_risk$data3 = _risk$data3.city) === null || _risk$data3 === void 0 ? void 0 : _risk$data3.province) || null\n },\n gender: {\n code: (risk === null || risk === void 0 || (_risk$data4 = risk.data) === null || _risk$data4 === void 0 || (_risk$data4 = _risk$data4.gender) === null || _risk$data4 === void 0 ? void 0 : _risk$data4.code) || null,\n name: (risk === null || risk === void 0 || (_risk$data5 = risk.data) === null || _risk$data5 === void 0 || (_risk$data5 = _risk$data5.gender) === null || _risk$data5 === void 0 ? void 0 : _risk$data5.name) || null\n },\n birthdate: (risk === null || risk === void 0 || (_risk$data6 = risk.data) === null || _risk$data6 === void 0 ? void 0 : _risk$data6.birthdate) || null,\n savings: (risk === null || risk === void 0 || (_risk$data7 = risk.data) === null || _risk$data7 === void 0 ? void 0 : _risk$data7.savings) || null,\n identification: (_risk$data$identifica = risk === null || risk === void 0 || (_risk$data8 = risk.data) === null || _risk$data8 === void 0 ? void 0 : _risk$data8.identification) !== null && _risk$data$identifica !== void 0 ? _risk$data$identifica : null,\n firstName: (_risk$data$firstName = risk === null || risk === void 0 || (_risk$data9 = risk.data) === null || _risk$data9 === void 0 ? void 0 : _risk$data9.firstName) !== null && _risk$data$firstName !== void 0 ? _risk$data$firstName : null,\n lastName: (_risk$data$lastName = risk === null || risk === void 0 || (_risk$data10 = risk.data) === null || _risk$data10 === void 0 ? void 0 : _risk$data10.lastName) !== null && _risk$data$lastName !== void 0 ? _risk$data$lastName : null,\n spouse: (_risk$data$spouse = risk === null || risk === void 0 || (_risk$data11 = risk.data) === null || _risk$data11 === void 0 ? void 0 : _risk$data11.spouse) !== null && _risk$data$spouse !== void 0 ? _risk$data$spouse : null,\n values: (risk === null || risk === void 0 || (_risk$data12 = risk.data) === null || _risk$data12 === void 0 ? void 0 : _risk$data12.values) || null,\n activity: (risk === null || risk === void 0 || (_risk$data13 = risk.data) === null || _risk$data13 === void 0 ? void 0 : _risk$data13.activity) || null,\n bloodPressure: (risk === null || risk === void 0 || (_risk$data14 = risk.data) === null || _risk$data14 === void 0 ? void 0 : _risk$data14.bloodPressure) || null,\n height: (risk === null || risk === void 0 || (_risk$data15 = risk.data) === null || _risk$data15 === void 0 ? void 0 : _risk$data15.height) || null,\n weight: (risk === null || risk === void 0 || (_risk$data16 = risk.data) === null || _risk$data16 === void 0 ? void 0 : _risk$data16.weight) || null\n },\n groupedEconomicValues: []\n };\n })) || []\n }\n };\n return _context2.abrupt(\"return\", quotation);\n case 2:\n case \"end\":\n return _context2.stop();\n }\n }, _callee2);\n }));\n return function getQuotationDetail(_x2) {\n return _ref2.apply(this, arguments);\n };\n}();\nvar getQuotationByCode = /*#__PURE__*/function () {\n var _ref3 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee3(response) {\n var _response$quotationNu, _response$productCode, _response$sectionCode;\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee3$(_context3) {\n while (1) switch (_context3.prev = _context3.next) {\n case 0:\n objectMapped = {\n code: ((_response$quotationNu = response.quotationNumber) === null || _response$quotationNu === void 0 ? void 0 : _response$quotationNu.toString()) || null,\n number: response.activityCode || 0,\n creationDate: response.vigencyDateFrom || null,\n expirationDate: response.vigencyDateTo || null,\n validity: {\n code: \"N/A\",\n name: \"N/A\",\n months: \"N/A\"\n },\n status: {\n code: \"N/A\",\n name: \"N/A\"\n },\n paymentFrequency: {\n name: \"N/A\",\n code: \"N/A\",\n months: 0\n },\n email: \"N/A\",\n phone: \"N/A\",\n intermediary: {\n code: \"N/A\",\n name: \"N/A\",\n roles: {}\n },\n commercialStructure: {\n data: {\n name: \"N/A\",\n code: \"N/A\",\n version: 0,\n description: \"N/A\",\n status: {\n name: \"N/A\",\n code: \"N/A\"\n }\n },\n intermediaries: {\n values: [{\n code: \"N/A\",\n name: \"N/A\",\n licence: \"N/A\",\n role: {\n name: \"N/A\",\n code: \"N/A\"\n },\n status: {\n name: \"N/A\",\n code: \"N/A\"\n },\n group: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }]\n }\n },\n product: {\n name: \"N/A\",\n code: (response === null || response === void 0 || (_response$productCode = response.productCode) === null || _response$productCode === void 0 ? void 0 : _response$productCode.toString()) || null,\n version: 0,\n subsection: {\n name: \"N/A\",\n code: \"N/A\",\n section: {\n name: \"N/A\",\n code: (response === null || response === void 0 || (_response$sectionCode = response.sectionCode) === null || _response$sectionCode === void 0 ? void 0 : _response$sectionCode.toString()) || null,\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n category: {\n name: \"N/A\",\n code: \"N/A\"\n }\n }\n },\n status: {\n code: \"N/A\",\n name: \"N/A\"\n },\n currency: {\n name: \"N/A\",\n code: \"N/A\",\n mnemonic: \"N/A\",\n symbol: \"N/A\"\n }\n },\n productSegment: {\n coverages: [],\n expenses: [],\n name: \"N/A\",\n code: \"N/A\",\n version: 0,\n description: \"N/A\"\n },\n values: {\n risks: [{\n code: \"N/A\",\n coverages: [{\n code: \"N/A\",\n name: \"N/A\",\n deductible: {\n name: \"N/A\",\n code: \"N/A\",\n value: 0,\n appliedValue: 0\n },\n economicValues: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n value: 0\n }],\n coverageValues: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n value: 0\n }]\n }],\n data: {},\n adherents: [{\n code: \"N/A\",\n coverages: [{\n code: \"N/A\",\n name: \"N/A\",\n deductible: {\n name: \"N/A\",\n code: \"N/A\",\n value: 0,\n appliedValue: 0\n },\n economicValues: [{\n type: \"N/A\",\n code: \"N/A\"\n }],\n coverageValues: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n value: 0\n }]\n }],\n data: {}\n }]\n }],\n expenses: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n value: 0\n }],\n groupedEconomicValues: [{\n type: {\n name: \"N/A\",\n code: \"N/A\"\n },\n value: 0\n }],\n commercialAgreement: {}\n }\n };\n return _context3.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context3.stop();\n }\n }, _callee3);\n }));\n return function getQuotationByCode(_x3) {\n return _ref3.apply(this, arguments);\n };\n}();\nvar getQuotationByCode_Request = function getQuotationByCode_Request(inputParams) {\n return {};\n};\nvar getQuotations_Request = function getQuotations_Request(inputParams) {\n return {\n number: inputParams.quotationNumber || undefined,\n from: inputParams.dateFrom || undefined,\n to: inputParams.dateTo || undefined\n };\n};\nvar quotationStandardPlanCreationMapped = function quotationStandardPlanCreationMapped(params) {\n if (!params) return null;\n return {\n sectionCode: 17,\n // no recibe se asigna 17 por defecto\n paymentTypeCode: (0,_helpers_mappingHelpers__WEBPACK_IMPORTED_MODULE_0__.mapPaymentFrequency)(params.paymentFrequencyCode),\n productCode: (0,_helpers_mappingHelpers__WEBPACK_IMPORTED_MODULE_0__.mapProductCode)(params.productCode),\n provinceCode: 1 // no recibe provincia, se asigna 1 por defecto\n };\n};\nvar quotationVariablePlanCreationMapped = function quotationVariablePlanCreationMapped(params) {\n var _params$risks$, _params$risks$2;\n if (!params) return null;\n return {\n sectionCode: 17,\n // no recibe se asigna 17 por defecto\n paymentTypeCode: (0,_helpers_mappingHelpers__WEBPACK_IMPORTED_MODULE_0__.mapPaymentFrequency)(params.paymentFrequencyCode),\n productCode: (0,_helpers_mappingHelpers__WEBPACK_IMPORTED_MODULE_0__.mapProductCode)(params.productCode),\n provinceCode: 1,\n // no recibe provincia, se asigna 1 por defecto\n birthdate: (_params$risks$ = params.risks[0]) === null || _params$risks$ === void 0 ? void 0 : _params$risks$.birthDate,\n insuredAmount: ((_params$risks$2 = params.risks[0]) === null || _params$risks$2 === void 0 || (_params$risks$2 = _params$risks$2.coverages[0]) === null || _params$risks$2 === void 0 || (_params$risks$2 = _params$risks$2.values.find(function (v) {\n return v.code === \"INSURED_AMOUNT\";\n })) === null || _params$risks$2 === void 0 ? void 0 : _params$risks$2.value) || 0\n };\n};\nvar getActivityList = /*#__PURE__*/function () {\n var _ref4 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee4(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee4$(_context4) {\n while (1) switch (_context4.prev = _context4.next) {\n case 0:\n objectMapped = {\n values: response.activities.map(function (a) {\n return {\n code: a.code,\n name: a.name\n };\n })\n };\n return _context4.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context4.stop();\n }\n }, _callee4);\n }));\n return function getActivityList(_x4) {\n return _ref4.apply(this, arguments);\n };\n}();\nvar getProductsBySubsections = /*#__PURE__*/function () {\n var _ref5 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee5(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee5$(_context5) {\n while (1) switch (_context5.prev = _context5.next) {\n case 0:\n objectMapped = {\n values: response.products.map(function (item) {\n return {\n name: item.name,\n code: item.code,\n version: item.version,\n subsection: (item === null || item === void 0 ? void 0 : item.subsection) || null,\n fieldExclusions: (item === null || item === void 0 ? void 0 : item.exclusions) || null,\n fields: (item === null || item === void 0 ? void 0 : item.fieldValues) || (item === null || item === void 0 ? void 0 : item.fields) || null\n };\n })\n };\n return _context5.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context5.stop();\n }\n }, _callee5);\n }));\n return function getProductsBySubsections(_x5) {\n return _ref5.apply(this, arguments);\n };\n}();\nvar getProductParameters = /*#__PURE__*/function () {\n var _ref6 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee6(item) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee6$(_context6) {\n while (1) switch (_context6.prev = _context6.next) {\n case 0:\n objectMapped = {\n name: item.name,\n code: item.code,\n version: item.version,\n subsection: (item === null || item === void 0 ? void 0 : item.subsection) || null,\n fieldExclusions: (item === null || item === void 0 ? void 0 : item.exclusions) || null,\n fields: (item === null || item === void 0 ? void 0 : item.fields) || null\n };\n return _context6.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context6.stop();\n }\n }, _callee6);\n }));\n return function getProductParameters(_x6) {\n return _ref6.apply(this, arguments);\n };\n}();\nvar getPaymentFrecuencies = /*#__PURE__*/function () {\n var _ref7 = _asyncToGenerator(/*#__PURE__*/_regeneratorRuntime().mark(function _callee7(response) {\n var objectMapped;\n return _regeneratorRuntime().wrap(function _callee7$(_context7) {\n while (1) switch (_context7.prev = _context7.next) {\n case 0:\n objectMapped = {\n frequencies: response.frequencies.map(function (a) {\n return {\n name: a.name,\n code: a.code,\n months: a.months\n };\n })\n };\n return _context7.abrupt(\"return\", objectMapped);\n case 2:\n case \"end\":\n return _context7.stop();\n }\n }, _callee7);\n }));\n return function getPaymentFrecuencies(_x7) {\n return _ref7.apply(this, arguments);\n };\n}();\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/quotation/index.js?");
140
+
141
+ /***/ }),
142
+
143
+ /***/ "./src/mapper/modules/request/index.js":
144
+ /*!*********************************************!*\
145
+ !*** ./src/mapper/modules/request/index.js ***!
146
+ \*********************************************/
147
+ /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
148
+
149
+ eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ getRequestDetail: () => (/* binding */ getRequestDetail),\n/* harmony export */ getRequest_Params: () => (/* binding */ getRequest_Params)\n/* harmony export */ });\nvar getRequest_Params = function getRequest_Params(i) {\n return {\n number: i.quotationNumber,\n statusCode: i.status,\n productCode: i.productCode,\n from: i.creationDateFrom,\n to: i.creationDateTo\n };\n};\nvar getRequestDetail = function getRequestDetail(data) {\n var mappedCoverages = data.coverages.map(function (cov) {\n return {\n code: cov.code || null,\n name: cov.name || null,\n deductible: null,\n economicValues: [],\n coverageValues: cov.coverageValues.map(function (val) {\n return {\n value: val.value,\n type: {\n name: val.type.name,\n code: val.type.code\n }\n };\n })\n };\n });\n var request = {\n code: data.number,\n commercialStructure: null,\n creationDate: data.creationDate,\n email: data.insured.email,\n expirationDate: (data === null || data === void 0 ? void 0 : data.expirationDate) || null,\n holder: data.holder || null,\n intermediary: null,\n legalConstraint: null,\n number: data.number || null,\n paymentMethods: {\n payment: data.payment\n },\n paymentFrequency: data.payment.period || null,\n phone: data.insured.phoneNumber || null,\n product: data.product || null,\n productSegment: null,\n quotationNumber: data.quotationNumber || null,\n quotationCode: data.quotationNumber || null,\n requiresBilling: null,\n status: data.status || null,\n validity: null,\n values: {\n risks: [{\n coverages: mappedCoverages\n }]\n } || null,\n vigencyDateFrom: null,\n wordingPlan: null,\n holderPep: data.holderPep,\n holderSoi: data.holderSoi,\n insured: data.insured || null,\n questionnaires: data.questionnaires || null,\n spouse: data.spouse || null\n };\n return request;\n};\n\n//# sourceURL=webpack://sysone-api-mapper/./src/mapper/modules/request/index.js?");
150
+
151
+ /***/ }),
152
+
153
+ /***/ "axios":
154
+ /*!************************!*\
155
+ !*** external "axios" ***!
156
+ \************************/
157
+ /***/ ((module) => {
158
+
159
+ module.exports = require("axios");
160
+
161
+ /***/ }),
162
+
163
+ /***/ "dayjs":
164
+ /*!************************!*\
165
+ !*** external "dayjs" ***!
166
+ \************************/
167
+ /***/ ((module) => {
168
+
169
+ module.exports = require("dayjs");
170
+
171
+ /***/ }),
172
+
173
+ /***/ "dayjs/plugin/customParseFormat":
174
+ /*!*************************************************!*\
175
+ !*** external "dayjs/plugin/customParseFormat" ***!
176
+ \*************************************************/
177
+ /***/ ((module) => {
178
+
179
+ module.exports = require("dayjs/plugin/customParseFormat");
180
+
181
+ /***/ })
182
+
183
+ /******/ });
184
+ /************************************************************************/
185
+ /******/ // The module cache
186
+ /******/ var __webpack_module_cache__ = {};
187
+ /******/
188
+ /******/ // The require function
189
+ /******/ function __webpack_require__(moduleId) {
190
+ /******/ // Check if module is in cache
191
+ /******/ var cachedModule = __webpack_module_cache__[moduleId];
192
+ /******/ if (cachedModule !== undefined) {
193
+ /******/ return cachedModule.exports;
194
+ /******/ }
195
+ /******/ // Create a new module (and put it into the cache)
196
+ /******/ var module = __webpack_module_cache__[moduleId] = {
197
+ /******/ // no module.id needed
198
+ /******/ // no module.loaded needed
199
+ /******/ exports: {}
200
+ /******/ };
201
+ /******/
202
+ /******/ // Execute the module function
203
+ /******/ __webpack_modules__[moduleId](module, module.exports, __webpack_require__);
204
+ /******/
205
+ /******/ // Return the exports of the module
206
+ /******/ return module.exports;
207
+ /******/ }
208
+ /******/
209
+ /************************************************************************/
210
+ /******/ /* webpack/runtime/compat get default export */
211
+ /******/ (() => {
212
+ /******/ // getDefaultExport function for compatibility with non-harmony modules
213
+ /******/ __webpack_require__.n = (module) => {
214
+ /******/ var getter = module && module.__esModule ?
215
+ /******/ () => (module['default']) :
216
+ /******/ () => (module);
217
+ /******/ __webpack_require__.d(getter, { a: getter });
218
+ /******/ return getter;
219
+ /******/ };
220
+ /******/ })();
221
+ /******/
222
+ /******/ /* webpack/runtime/define property getters */
223
+ /******/ (() => {
224
+ /******/ // define getter functions for harmony exports
225
+ /******/ __webpack_require__.d = (exports, definition) => {
226
+ /******/ for(var key in definition) {
227
+ /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
228
+ /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
229
+ /******/ }
230
+ /******/ }
231
+ /******/ };
232
+ /******/ })();
233
+ /******/
234
+ /******/ /* webpack/runtime/hasOwnProperty shorthand */
235
+ /******/ (() => {
236
+ /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
237
+ /******/ })();
238
+ /******/
239
+ /******/ /* webpack/runtime/make namespace object */
240
+ /******/ (() => {
241
+ /******/ // define __esModule on exports
242
+ /******/ __webpack_require__.r = (exports) => {
243
+ /******/ if(typeof Symbol !== 'undefined' && Symbol.toStringTag) {
244
+ /******/ Object.defineProperty(exports, Symbol.toStringTag, { value: 'Module' });
245
+ /******/ }
246
+ /******/ Object.defineProperty(exports, '__esModule', { value: true });
247
+ /******/ };
248
+ /******/ })();
249
+ /******/
250
+ /************************************************************************/
251
+ /******/
252
+ /******/ // startup
253
+ /******/ // Load entry module and return exports
254
+ /******/ // This entry module can't be inlined because the eval devtool is used.
255
+ /******/ var __webpack_exports__ = __webpack_require__("./index.js");
256
+ /******/ module.exports = __webpack_exports__;
257
+ /******/
258
+ /******/ })()
259
+ ;
@@ -1 +1 @@
1
- /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
1
+ /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */
package/index.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import { apiCall } from "./services";
2
2
  import { endpoints } from "./servicesData";
3
3
  import axiosInstance from "./axiosInstance";
4
- import { apiMapper } from "./src/mapper/Mapper";
4
+ import { configureApiMapper, apiMapper } from "./src/mapper/Mapper";
5
5
 
6
6
 
7
7
 
8
8
 
9
- export { apiCall, apiMapper, endpoints, axiosInstance };
9
+ export { apiCall, apiMapper, endpoints, axiosInstance, configureApiMapper };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sysone-api-mapper",
3
- "version": "1.0.138",
3
+ "version": "1.0.139",
4
4
  "description": "Paquete mapper para portal de productores",
5
5
  "main": "src/index.js",
6
6
  "scripts": {