Merge remote-tracking branch 'cruales/cruales'
This commit is contained in:
parent
b5ef6cffd8
commit
67a73c6309
|
|
@ -0,0 +1 @@
|
|||
/target/
|
||||
|
|
@ -1,4 +1,16 @@
|
|||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<web-app version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
|
||||
|
||||
<web-app version="3.0" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd">
|
||||
<servlet>
|
||||
<servlet-name>com.qsoft.wmp.services.rest.ApplicationConfig</servlet-name>
|
||||
<init-param>
|
||||
<param-name>jersey.config.server.provider.classnames</param-name>
|
||||
<param-value>org.glassfish.jersey.jackson.JacksonFeature</param-value>
|
||||
</init-param>
|
||||
<load-on-startup>1</load-on-startup>
|
||||
</servlet>
|
||||
<servlet-mapping>
|
||||
<servlet-name>com.qsoft.wmp.services.rest.ApplicationConfig</servlet-name>
|
||||
<url-pattern>/servicios/*</url-pattern>
|
||||
</servlet-mapping>
|
||||
</web-app>
|
||||
|
|
|
|||
|
|
@ -4,7 +4,7 @@
|
|||
"canal": null,
|
||||
"medio": null,
|
||||
"aplicacion": "WeERPV1.0",
|
||||
"tipoTransaccion": "0101151",
|
||||
"tipoTransaccion": "0101150",
|
||||
"usuario": "james",
|
||||
"uuid": "2e25aed60f2d4c63e33864a638b906f2df987a9b37ce3f8dafde7b565b2a6c41",
|
||||
"fechaHora": "20/05/2020 23:55:36",
|
||||
|
|
@ -14,45 +14,79 @@
|
|||
},
|
||||
"bodyIn": {
|
||||
"tipoAccion": 1,
|
||||
"entidad": "FacturaCompra",
|
||||
"entidad": "DetalleLiquidacion",
|
||||
"entidades": [
|
||||
{
|
||||
"facEstablecimiento": "001",
|
||||
"facPtoEmision": "001",
|
||||
"facSecuencial": "00000001",
|
||||
"facClaveAcceso": null,
|
||||
"facAutorizacion": null,
|
||||
"facTotalDescuentos": null,
|
||||
"facTotalImpuestos": null,
|
||||
"facTotalOtros": null,
|
||||
"facImporte": null,
|
||||
"facTotal": null,
|
||||
"facAdelanto": null,
|
||||
"facPendiente": null,
|
||||
"facReferencia": null,
|
||||
"facPropina": null,
|
||||
"facFechaRegistro": null,
|
||||
"facFechaAutorizacion": null,
|
||||
"facDescripcion": null,
|
||||
"facObservacion": null,
|
||||
"facDetalle": null,
|
||||
"facDinamico": "CUANDO SE ADQUIERE SERVICIOS O CONSUMIBLES QUE NO GENERAN ENTRADA SE AGREGA AQUI",
|
||||
"ejeCodigo": null,
|
||||
"empCodigo": null,
|
||||
"proCodigo": 1,
|
||||
{
|
||||
"favCodigo": null,
|
||||
"favEstablecimiento": "001",
|
||||
"favPtoEmision": "001",
|
||||
"favSecuencial": "00000095",
|
||||
"favReferencia": null,
|
||||
"favClaveAcceso": null,
|
||||
"favAutorizacion": null,
|
||||
"favFechaRegistro": null,
|
||||
"favFechaAutorizacion": null,
|
||||
"favTotalImpuestos": null,
|
||||
"favTotalDescuentos": null,
|
||||
"favAdelanto": null,
|
||||
"favPendiente": null,
|
||||
"favTotalOtros": null,
|
||||
"favPropina": null,
|
||||
"favImporte": 50.2,
|
||||
"favTotal": null,
|
||||
"favDescripcion": null,
|
||||
"favObservacion": "Factura de prueba",
|
||||
"favDinamico": null,
|
||||
"detEstado": null,
|
||||
"detTipo": null,
|
||||
"cliCodigo": 1,
|
||||
"ejeCodigo": null,
|
||||
"sucCodigo": null,
|
||||
"usuCodigo": null,
|
||||
"cliMailNotifica": "test@qsoftec.com",
|
||||
"favFechaPago": null,
|
||||
"favFechaEmision": "2020-07-12 13:19:16",
|
||||
"detalle": [
|
||||
{
|
||||
"denCantidad": 2.0,
|
||||
"denPrecioCompra": 89.3,
|
||||
"denFecProduccion": 1590073789081,
|
||||
"denFecCaducidad": 1590073789081,
|
||||
"artCodigo": 1,
|
||||
"bodCodigo": 1,
|
||||
"detUnidad": null,
|
||||
"entCodigo": null
|
||||
"defOrden": null,
|
||||
"defCantidad": null,
|
||||
"defPrecioUnitario": null,
|
||||
"defValorDescuentos": null,
|
||||
"defValorImpuestos": null,
|
||||
"defValorOtros": null,
|
||||
"defDetalleAd": null,
|
||||
"defImporte": null,
|
||||
"defTotal": null,
|
||||
"defDescripcion": null,
|
||||
"artCodigo": null,
|
||||
"impuesto": [
|
||||
{
|
||||
"imfValor": null,
|
||||
"imfEstado": null,
|
||||
"rubCodigo": null
|
||||
}
|
||||
],
|
||||
"descuento": [
|
||||
{
|
||||
"dsfValor": null,
|
||||
"dsfEstado": null,
|
||||
"rubCodigo": null
|
||||
}
|
||||
]
|
||||
}
|
||||
],
|
||||
"impuesto": [
|
||||
{
|
||||
"imfValor": null,
|
||||
"imfEstado": null,
|
||||
"rubCodigo": null
|
||||
}
|
||||
],
|
||||
"descuento": [
|
||||
{
|
||||
"dsfValor": null,
|
||||
"dsfEstado": null,
|
||||
"rubCodigo": null
|
||||
}
|
||||
]
|
||||
}
|
||||
|
|
|
|||
|
|
@ -12,7 +12,8 @@ import com.qsoft.erp.dominio.AccionGenerica;
|
|||
import com.qsoft.erp.dto.DocumentoDTO;
|
||||
import com.qsoft.erp.dto.EstadoLiquidacionDTO;
|
||||
import com.qsoft.erp.dto.LiquidacionDTO;
|
||||
import com.qsoft.erp.dto.PolizaDTO;
|
||||
import com.qsoft.erp.dto.RetencionDTO;
|
||||
import com.qsoft.erp.dto.RubroRetenidoDTO;
|
||||
import com.qsoft.wmp.services.rest.AccionResource;
|
||||
import com.qsoft.wmp.services.rest.ConsultaResource;
|
||||
import com.qsoft.wmp.services.xsd.EntradaAccion;
|
||||
|
|
@ -20,6 +21,7 @@ import com.qsoft.wmp.services.xsd.EntradaConsulta;
|
|||
import com.qsoft.wmp.services.xsd.SalidaConsulta;
|
||||
import java.io.IOException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
|
@ -32,7 +34,7 @@ public class Tester {
|
|||
|
||||
public static void main(String[] args) throws IOException {
|
||||
System.out.println("TEST " + DominioConstantes.getDateTime());
|
||||
testAccionService();
|
||||
testAccionService(); //0101154
|
||||
}
|
||||
|
||||
public static void testConsultaService() throws IOException {
|
||||
|
|
@ -67,7 +69,7 @@ public class Tester {
|
|||
ObjectMapper maper = new ObjectMapper();
|
||||
EntradaAccion entrada = new EntradaAccion();
|
||||
entrada.getBodyIn().setTipoAccion(AccionGenerica.GUARDA);
|
||||
entrada.getBodyIn().setEntidad(EntidadEnum.DetalleLiquidacion.name());
|
||||
entrada.getBodyIn().setEntidad(EntidadEnum.Retencion.name());
|
||||
List<Map<String, Object>> entidades = new ArrayList<>();
|
||||
//TODO: agregar entidades
|
||||
entrada.getBodyIn().setEntidades(entidades);
|
||||
|
|
@ -76,24 +78,25 @@ public class Tester {
|
|||
System.out.println("JSON=> " + s);
|
||||
AccionResource ar = new AccionResource();
|
||||
System.out.println("POSTING....");
|
||||
List<PolizaDTO> data = new ArrayList<>();
|
||||
PolizaDTO pol = new PolizaDTO();
|
||||
pol.setDetTipoIdentificacion(3);
|
||||
pol.setPerCedulaTitular("1715060073");
|
||||
pol.setDetModalidad(25);
|
||||
pol.setDetPeriodicidad(17200);
|
||||
pol.setDetFormaPago(23516);
|
||||
pol.setDetIfi(17205);
|
||||
pol.setDetSucursalIfi(23484);
|
||||
pol.setDetPromocion(23584);
|
||||
pol.setDetTipoCuenta(17187);
|
||||
pol.setEmpCodigo(2);
|
||||
pol.setCedulaDebito("1715060012");
|
||||
pol.setCuentaDebito("123456789");
|
||||
pol.setPolBroker("Asesor CPN");
|
||||
List<RetencionDTO> data = new ArrayList<>();
|
||||
|
||||
RetencionDTO retencion = new RetencionDTO();
|
||||
retencion.setRetEstablecimiento("001");
|
||||
retencion.setRetPtoEmision("001");
|
||||
retencion.setRetSecuencial("00000095");
|
||||
retencion.setRetFechaEmision(new Date());
|
||||
retencion.setCliCodigo(1);
|
||||
retencion.setRetTotalRetenido(50.20);
|
||||
retencion.setRetReferencia("Retencion para factura de prueba");
|
||||
|
||||
|
||||
List<RubroRetenidoDTO> detalle = new ArrayList<>();
|
||||
|
||||
detalle.add(new RubroRetenidoDTO());
|
||||
retencion.setDetalle(detalle);
|
||||
|
||||
data.add(retencion);
|
||||
|
||||
data.add(pol);
|
||||
|
||||
s = maper.writeValueAsString(data);
|
||||
System.out.println("JSON=> " + s);
|
||||
// SalidaAccion salida = ar.postJson(entrada);
|
||||
|
|
|
|||
|
|
@ -0,0 +1,48 @@
|
|||
{
|
||||
"headerIn": {
|
||||
"dispositivo": "WeLaptop",
|
||||
"canal": "01",
|
||||
"medio": "01",
|
||||
"aplicacion": "WeMedicalProV1.0",
|
||||
"tipoTransaccion": "0101110",
|
||||
"usuario": "james",
|
||||
"uuid": "ALGUN TOKEN",
|
||||
"fechaHora": null,
|
||||
"idioma": null,
|
||||
"empresa": null,
|
||||
"geolocalizacion": null
|
||||
},
|
||||
"bodyIn": {
|
||||
"tipoNotificacion": 1,
|
||||
"parametros": {
|
||||
"[ADJUNTO]": "/data/wmp/poliza/PREMIUM-signed.pdf",
|
||||
"[ASUNTO]": "Bienvenido al servicio de medicina Prepagada de Caridel",
|
||||
"[CLIENTE]": "EDISON RAMIRO",
|
||||
"[COBERTURA]": "25000.0",
|
||||
"[COMPROBANTE]": "POLIZA",
|
||||
"[EMAIL]": "karito_634@yahoo.es",
|
||||
"[EMISOR]": "CARIDEL S.A.",
|
||||
"[EMISOR_MAIL]": "notificaciones@caridelsa.com",
|
||||
"[EMISOR_WEB]": "http://cpnsalud.caridel.net/",
|
||||
"[FECHAEMI]": "01/04/2020 23:40:30",
|
||||
"[IDENTIFICACION]": "1002366654",
|
||||
"[NUMDOC]": "POL0000000332",
|
||||
"[PLAN]": "MASIVOS PREMIUN CPN"
|
||||
},
|
||||
"adjuntos": [
|
||||
{
|
||||
"nombre": "archivo1.pdf",
|
||||
"archivo": "UklGRoJgAABXRUJQVlA4IHZgAADQAwGdASoAAQABPjEUiEKiISEXq+4MIAMEtQBYU7REd+X/vH7S/lv8ndg......."
|
||||
},
|
||||
{
|
||||
"nombre": "archivo2.txt",
|
||||
"archivo": "zU4pk7xWlI3KLzi7huKBDIulPve0zFmNc30vUd3a29NIcoHBLRNxzamSywbh1dGBh2drEZI5qvE4WEvRutK5...."
|
||||
},
|
||||
{
|
||||
"nombre": "archivo3.jpg",
|
||||
"archivo": "3qwduvkya8kAXnvUbjh4X7oXRWt59pAIq+77Awuqo6CtaYmslelq0WZP9YG69Ons09NkwRKf5KFfEezMo+6VRyzpEln6qTMMUH0..."
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -4,20 +4,55 @@
|
|||
"canal": null,
|
||||
"medio": null,
|
||||
"aplicacion": "WeMedicalProV1.0",
|
||||
"tipoTransaccion": "0101000",
|
||||
"tipoTransaccion": "0101154",
|
||||
"usuario": "james",
|
||||
"uuid": "7cbec0b8ec642ddbd7b9b24a35e39b70938d",
|
||||
"uuid": "4a410b3e2eebc30e865d6935aec3481bb3d394d863b28157d6f06bcc280635bd",
|
||||
"fechaHora": null,
|
||||
"idioma": null,
|
||||
"empresa": null,
|
||||
"geolocalizacion": null
|
||||
},
|
||||
"bodyIn": {
|
||||
"maximoRegistros": 10,
|
||||
"tipoConsulta": 1,
|
||||
"entidad": "Empresa",
|
||||
"parametros": {
|
||||
"tipoNemonico": "COMERC"
|
||||
}
|
||||
"tipoAccion": 1,
|
||||
"entidad": "Retencion",
|
||||
"entidades": [
|
||||
{
|
||||
"retCodigo": null,
|
||||
"retEstablecimiento": "001",
|
||||
"retPtoEmision": "001",
|
||||
"retSecuencial": "00000095",
|
||||
"retTotalBase": null,
|
||||
"retAutorizacion": null,
|
||||
"retClaveAcceso": null,
|
||||
"retFechaEmision": "01/07/2019 14:00:25",
|
||||
"retFechaRegistro": null,
|
||||
"retFechaAutorizacion": null,
|
||||
"retTotalRetenido": 50.2,
|
||||
"retReferencia": "Retencion para factura de prueba",
|
||||
"retEstado": null,
|
||||
"detTipo": null,
|
||||
"facCodigo": null,
|
||||
"favCodigo": null,
|
||||
"usuCodigo": null,
|
||||
"cliCodigo": 1,
|
||||
"sucCodigo": null,
|
||||
"proCodigo": null,
|
||||
"ejeCodigo": null,
|
||||
"detalle": [
|
||||
{
|
||||
"rucCodigo": null,
|
||||
"rucImpuesto": null,
|
||||
"rucCodSri": null,
|
||||
"rucBase": null,
|
||||
"rucPorcentaje": null,
|
||||
"rucRetencion": null,
|
||||
"rucDescripcion": null,
|
||||
"rucFechaRegistro": null,
|
||||
"retCodigo": null,
|
||||
"rubCodigo": null
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue