Home

Manual Técnico - Repositorio CISC

image

Contents

1. public Session getSession return DAOUtil getSessionFactory getCurrentSession 48 com general modelo persistentes J BaseHibernateDAO java gt J CiclosFacturaciones java gt JB CiclosFacturacionesDAO java gt M Clientes java ClientesDAO java package com general modelo persistentes FECHA 20 06 2009 AUTOR GRUPO 3 a COMENTARIO CLASE BEAN QU REPRESENTA LA TABLA ciclos facturaciones DE LA BASE DE DATOS x import java util Date import java util HashSet import java util Set T Xxx x CiclosFacturaciones entity author MyEclipse Persistence Tools a public class CiclosFacturaciones implements java io Serializable Fields private Integer idCiclo private String descripcionCiclo 42 private String estado private Date fechaRegistro private String observacion private Date fechaActualizacion private String usuariolngreso private Set contratoses new HashSet 0 private Integer dialnicio private Integer diaFin Constructors public Integer getDiaFin return diaFin public void setDiaFin Integer diaFin this diaFin diaFin public Integer getDiaInicio return dialnicio public void setDiaInicio Integer dialnicio this diaInicio dialnicio def
2. modu request getSession setAttribute OPC_NO_ASIG losNoAsigandos DAOUtil commit 4 E facturacionlsp2 a GP src gt H com general bo gt 8 com general escuchadores gt H com general filtros generales gt H com general modelo persistentes gt D F com general struts gt B 4 H com general gt M ActualizarParametrosForm jawa gt H ActualizarProductoForm java I CambiarClaveUsuarioForm java 151 Generated by MyEclipse Struts Template path templates java JavaClass vtl Ng package com general struts form import javax servlet http HttpServletRequest import org apache struts action ActionErrors import org apache struts action ActionForm import org apache struts action ActionMapping Xxx x MyEclipse Struts x Creation date 08 02 2007 XDoclet definition struts form name generacionFacturasForm public class GeneracionFacturasForm extends ActionForm Generated fields 7 fecha property private String fecha ciclo property private String ciclo Generated Methods x Xxx 152 Method validate param mapping param request return ActionErrors XA ey public ActionErrors validate ActionMapping mapping HttpServletRequest request TODO Auto generated method stub return null Xxx x Method reset x param mapping x param request El p
3. Buscar por ruc persona personaDao findByPropertyUnique personaDao RUC datoIdentificacion if persona null persona personaDao findByPropertyUnique personaDao PASAPORT datoIdentificacion GI if persona null if accion equals 1 request getSession setAttribute IDENTIFICACIONIN CIO datoldentificacion request getSession setAttribute ASIG 1 return mapping findForward busquedaFallida throw new Exception No se encontro persona registrada con el numero de identificaci n datoldentificacion Si encontro persona ahora buscar cliente Set clientes persona getClienteses Clientes cli null Iterator it 23 clientes iterator while ite hasNext cli Clientes ite next Si el client siempre si importar la opcion no exist deb if cli null Crear el cliente sin importar nada request getSession setAttribute PERSONAENCONTRADA persona request getSession setAttribute CLI ENTEENCONTRADO cli return mapping findForward procesoExitoso DAOUtil commit request getSession setAttribute PERSONAENCONTRADA persona request getSession setAttribute CLIENTEENCONTRADO 7 cli
4. import java util Date import java util Iterator import java util List import java util Set import java util Vector import javax servlet http HttpServletRequest import Javax servlet http HttpServletResponse import org apache struts action Action import org apache struts action ActionForm import org apache struts action ActionForward import org apache struts action ActionMapping persistentes Opciones persistentes OpcionesDAO persistentes OpcionesRoles persistentes OpcionesRolesDAO persistentes Roles persistentes RolesDAO persistentes Usuarios import com general modelo import com general modelo import com general modelo import com general modelo import com general modelo import com general modelo import com general modelo import com general util DAOUtil import com general util Sesion MyEclipse Struts XDoclet definition A E HF X path paginas transaccion redirect true struts a path paginas transaccion redirect true Creation date 08 02 2007 struts action validate true struts action forward name ok es seguridad gestionOpcionesRoles jsp ction forward name fallo es seguridad gestionOpcionesRoles jsp Action extends Action E public class AniadirOpcion Generated Methods Xxx x Method execute x param mapping param form 146 pa
5. public List findByEstado Object estado return findByProperty ESTADO estado public List findByObservacion Object observacion return findByProperty OBSERVACION observacion public List findByUsuarioIngreso Object usuariolngreso return findByProperty USUARIO INGRESO usuariolngreso ublic List findAll log debug finding all DetallesPagos instances try O String queryString from DetallesPagos Query queryObject getSession createQuery queryString return queryObject list 82 catch RuntimeException re log error find all failed re throw re public DetallesPagos merge DetallesPagos detachedInstance log debug merging DetallesPagos instance try 4 DetallesPagos result DetallesPagos getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re public void attachDirty DetallesPagos instance log debug attaching dirty DetallesPagos instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re throw re public void attachClean DetallesPagos instance log debug attaching clean DetallesPagos ins
6. throw new Exception No seleccionado planes por favor revisar if idCiclo null throw new Exception Seleccione ciclo por favor if idCiclo equals 1 throw new Exception Seleccione ciclo por favor if observacion null ha el el 33 throw new Exception Ingrese la observacion por favor if observacion trim equals throw new Exception Ingrese la observacion por favor Realizar la transaccion de creacion de contrato y servicio DAOUtil beginTransaction Contratos contrato creacionContrato persona cliente planes idCiclo observacion Usuarios request getSession getAttribute Sesion USUARIO getDescUsuario DAOUtil commit request getSession setAttribute CONTRATOACTUAL contrato Realizar la transaccion de creacion de contrato y servicio return mapping findForward procesoExitoso catch Exception e DAOUtil rollback e printStackTrace request getSession setAttribute TITULOERROR Creacion De Contrato request getSession setAttribute ERRORGENERAL e new Exception principalErrorte getMessage return mapping findForward procesoFallido private Contratos creacionContrato Personas persona Clientes cliente Vector planes String
7. catch Exception e 39 request getSession setAttribute TITULOERROR Creacion Usuario request getSession setAttribute ERRORGENERAL e new Exception principalError e getMessage return mapping findForward procesoFallido private void crearUsuario IngresoUsuarioForm ingresoUsuarioForm String descUsuario throws Exception TODO Auto generated method stub UsuariosDAO usuarioDao new UsuariosDAO Usuarios usuario new Usuarios PersonasDAO personaDao new PersonasDAO RolesDAO rolesDao new RolesDAO Validar el usuario List usuasrios usuarioDao findByDescUsuario ingresoUsuarioForm getDescripci onUsuario toUpperCase if usuasrios size gt O throw new Exception El usuario ingresoUsuarioForm getDescripcionUsuario toUpperCase ya se encuentra registrado por favor asignar otro Personas pers personaDao findById new Integer ingresoUsuarioForm getIdPersona Set users pers getUsuarioses if users size gt 0 throw new Exception La persona pers getPrimerNombre pers getApellidoPaterno ya tiene asignado un usuario usuario setDescUsuario ingresoUsuarioForm getDescrip cionUsuario toUpperCase usuario setEstado A usuario setFechaRegis
8. ox ay import java util import java util import java util Xxx COMENTARIO CLASE BEAN QUE LA BASE DE DATOS FECHA 20 06 2009 3 REPRESENTA LA TABLA CONTRATOS Date HashSet L Set Contratos entity author MyEclipse Persistence Tools public class Contratos implements java io Serializable Fields private private private private private private Integer idContrato Empleados empleados CiclosFacturaciones ciclosFacturaciones Clientes clientes String cuenta privat private private private private private private private private String estado Date fechaFin String plazo Date fechaInicio Date fechaRegistro Date fechaActualizacion String observacion String usuariol ngreso String valorReferencial Set facturases new HashSet 0 58 private Set serviciosContratadoses new HashSet 0 private Double precioPlan Constructors public Double getPrecioPlan return precioPlan public void setPrecioPlan Double precioPlan this precioPlan precioPlan default constructor public Contratos minimal constructor public Contratos Empleados empleados CiclosFacturaciones ciclosFacturaciones Clientes clientes String cuenta Date fechalnicio Date fechaRegistro String estado this empleados empleados his ciclosFactur
9. return siguienteNumero public void setSiguienteNumero Integer siguienteNumero this siguienteNumero siguienteNumero default constructor public SecuenciasFacturas full constructor public SecuenciasFacturas String numerolnicial String numeroFinal String estado Date fechaRegistro Date fechalnicio Date fechaFin Date fechaActualizacion String numeroAutorizacion String observacion String usuariolngreso this numeroInicial numeroInicial this numeroFinal numeroFinal this estado estado this fechaRegistro fechaRegistro this fechaInicio fechalnicio this fechaFin fechaFin this fechaActualizacion fechaActualizacion this numeroAutorizacion numeroAutorizacion this observacion observacion this usuariolngreso usuariolngreso Property accessors public Integer getIdSecuencia return this idSecuencia public void setIdSecuencia Integer idSecuencia this idSecuencia idSecuencia public String getNumeroInicial return this numeroInicial 124 public void setNumeroInicial String numeroInicial this numeroInicial numeroInicial public String getNumeroFinal return this numeroFinal public void setNumeroFinal String numeroFinal this numeroFinal numeroFinal public String getEstado return this estado public void setEstado String estado this estado estado publi
10. PARA LA VALIDACION DEL USUARIO VERIFICA USUARIO Y PASSWORD import java io UnsupportedEncodingException import java security InvalidAlgorithmParameterException import java security InvalidkeyException import java security NoSuchAlgorithmException import java security spec InvalidKeySpecException import javax crypto BadPaddingException import javax crypto IllegalBlockSizeException import javax crypto NoSuchPaddingException import com general modelo persistentes import com general util public class LoginBO implements Configuracion public Usuarios validarLoginReintentos String ps_user String ps_password throws Exception try Usuarios 1 usuario validarLogin ps user toUpperCase ps password return 1 usuario catch Exception e throw e7 public Usuarios cambiarClave String ps_user String ps claveActual String ps claveNueva throws Exception ps user ps user toUpperCase ps claveActual ps claveActual ps claveNueva ps claveNueva try DAOUtil beginTransaction j Usuarios 1_usuario null 1 usuario validarLogin ps user ps claveActual if ps claveActual equals ps claveNueva ExcepcionLogicaNegocio 1 e new ExcepcionLogicaNegocio l_e setMensajeUsuario La Clave Nueva debe ser diferente a la Clave Actual l_e setMensajeTecnico ps_claveActual equals ps_c laveNueva throw l_e
11. System out println Inicio de la aplicacion web if logger isEnabledFor Level INFO logger info Inicializado la aplicacion p_sc getServletContext getServletContextName catch Exception e e printStackTrace package com general escuchadores Incialmente comprueba si hay comunicacion con la base de datos por medio de la clase DAOUTI1 usando hibernate considerando que si no esta subida la base de datos no 16 sube la aplicacion x x mport javax servlet ServletRequestEvent mport javax servlet ServletRequestListener mport org apache log4j Logger mport com general util DAOUtil i i i ab public class ManejadorHibernateRequest implements ServletRequestListener static Logger logger Logger getLogger InicializadorContexto class public void requestDestroyed ServletRequestEvent p_sre try DAOUtil rollback catch Exception e public void requestInitialized ServletRequestEvent arg0 DAOUtil beginTransaction 4 EB com general filtros generales D FilSensarUserjava package com general filtros generales import Java io IOException import java util Date import Javax servlet Filter import javax servlet FilterChain import javax servlet FilterConf
12. if accion equals 1 return mapping findForward busquedal else Exitosa return mapping findForward procesol Exitoso catch Exception e e printStackTrace request getSession setAttribute TITULOERROR Busqueda Persona ir a crearlo 26 request getSession setAttribute ERRORGENERAL e new Exception principalError e getMessage if accion equals 1 return mapping findForward busquedaError else return mapping findForward procesoFallido Generated by MyEclipse Struts Templ ay package import import import import Na Ga do Tt import j import j import o import o import o import o import c import c import c import c import c import c Xxx MyEc ate com ava ava ava ava path templates java JavaClass vtl general struts action util Iterator util List util Set util Vector avax servlet http HttpServletRequest avax servlet http HttpServletResponse rg TG rg nae om om om om om om apache apache apache apache general model general model general model general model struts action Action struts action ActionForm struts action ActionForward struts action ActionMapping
13. datolden persona getCedula datoIden datoIden null datolIden if datoIden equals datolden persona getPasaporte datoIden datoIden null datoIden gt lt html gt lt head gt lt title gt JSP for IngresoUsuarioForm form lt title gt lt link rel stylesheet href lt request getContextPath gt css estiloFormas css type text css gt lt link gt lt script type text javascript 175 src lt request getContextPath gt js general js gt lt script gt lt script type text javascript language Javascript1 1 src lt request getContextPath gt 3s validacionesStruts Js gt lt seript gt lt script type text javascript gt function limpiar window open lt request getContextPath gt paginas tr ansacciones seguridad ingresoUsuario jsp TRABAJO function buscarCedula valor var dato valor var ruta if dato ruta lt S request getContextPath gt buscarIdentificacionPersona do d atoldentificacion dato saccion 1 window open ruta _self else alert Ingrese el numero de Identificacion function validarSiNumero numero obj if 0 9 S test numero alert Las identificaciones deben ser numericas wi LA obj value obj focus lt script gt lt head gt lt body gt lt 17
14. persistentes Opciones persistentes OpcionesDAO persistentes OpcionesRoles persistentes Roles O O O O general modelo persistentes RolesDAO general util DAOUtil Creation date ipse Struts 08 02 2007 et definition struts action validate true struts action forward name ok XDoc 27 path paginas transacciones seguridad gestionOpcionesRoles jsp redirect true struts action forward name fallo path paginas transacciones seguridad gestionOpcionesRoles jsp redirect true ti public class BuscarOpcionesModAction extends Action Generated Methods El Method execute param mapping param form param request param response return ActionForward ACA F F F N public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response TODO Auto generated method stub try Roles rol Roles request getSession getAttribute ROL_ENC String idOpcion request getParameter idOpcion DAOUtil beginTransaction j RolesDAO rolDao new RolesDAO Roles roll rolDao findById rol getIdRol OpcionesDAO opcDao new OpcionesDAO Opciones opc opcDao findById new Integer idOpcion Set opcionesRol roll getOpcionesRoleses Iterator totalOpc opcionesRol iterator
15. return this personas public void setPersonas Personas personas this personas personas public String getDescUsuario return this descUsuario public void setDescUsuario String descUsuario this descUsuario descUsuario public String getClave return this clave public void setClave String clave 137 this clave clave public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getUsuarioIngreso return this usuariolngreso public void setUsuariolngreso String usuariolngreso this usuariolngreso usuariolngreso public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public Set getLoginUsuarioses return this loginUsuarioses 138 public void setLoginUsuarioses Set loginUsuarioses this loginUsuarioses loginUsuarioses 4 facturacionlsp2 45
16. return this roles public void setRoles Roles roles this roles roles 108 public Personas getPersonas return this personas public void setPersonas Personas personas this personas personas public String getDescUsuario return this descUsuario public void setDescUsuario String descUsuario this descUsuario descUsuario public String getClave return this clave public void setClave String clave this clave clave public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion 109 public String getUsuariolngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public Set getLoginUsuarioses return this loginUsuarioses public void setLoginUs
17. E OO Script Activar usr bin perl use DBI db DBI mysal facturacionisp 127 0 0 1 username root 193 pass redes now localtime time values split now print values 1 values 2 values 4 H mesmag values 1 dbh DBI gt connect db username pass sql qq SELECT FROM reactivacion_servicios WHERE estado l dbh gt do sql sth dbh gt prepare sq sth gt execute Sfecha1 Svalues 4 5mes 01 print Sfecha1 while array sth gt fetchrow_array Sidac Sarray 0 ip array 3 iptables t nat A POSTROUTING o eth0 s ip 32 j MASQUERADE sq10 qq INSERT INTO nat ip VALUES Sip dbh gt do sq10 sth10 dbh gt prepare sq10 sth1 0 gt execute sq2 qq UPDATE reactivacion_servicios SET estado E WHERE estado I AND id reactivacion Sidac AND ip_maquina ip dbh gt do sq2 sth1 dbh gt prepare sq2 sth1 gt execute sqi6 qq UPDATE servicios contratados SET estado A valor_referencia_3 Automatico reactivado WHERE estado l AND valor referencia 2 Sip AN D descripcion servicio CORREO dbh gt do sq16 sth16 dbh gt prepare sq16 sth16 gt execute Script Corte_lotes usr bin perl use DBI db DBI mysal facturacionisp 127 0 0 1 username root pass redes now
18. getSession createQuery queryString catch RuntimeException re re public List findByDescripcion Object descripcion queryObject setParameter 0 value return queryObject list log error find by property name failed throw re return descripcion public List findByValorUnitario Object valorUnitario return findByProperty VALOR_UNITARIO valorUnitario findByProperty DESCRIPCION public List findByCantidad Object cantidad return findByProperty CANTIDAD cantidad public List findBySubtotal Object subtotal return findByProperty SUBTOTAL subtotal public List findByValorIva Object valorIva return findByProperty VALOR IVA valorlva public List findByValorIce Object valorIce return findByProperty VALOR ICE valorlce public List findByEstado Object estado return findByProperty ESTADO estado public List findByObservacion Object observacion 74 return findByProperty OBSERVACION observacion public List findByUsuariolngreso Object usuariolngreso return findByProperty USUARIO_INGRESO usuariolngreso public List findAll log debug finding all DetallesFacturas i
19. lt tr gt lt tr gt lt td class etiquetaForma width 20 gt Observacion lt td gt lt td class detalleForma width 30 colspan 3 gt lt html textarea property observacion rows 2 cols 130 onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off styleClass cajaTexto gt lt html errors property observacion gt lt td gt lt tr gt lt tr height 40 gt lt td class pieForma colspan 4 align center height 40 gt lt input type Reset value Limpiar class boton onclick limpiar gt lt html submit value Aceptar styleClass boton gt 178 lt td gt lt tr gt lt table gt lt html form gt lt body gt lt html gt 2 META INF 4 gt paginas 4 gt generales gt deluxe tree files y cambiarClave jsp lt page language java S gt lt DOCTYPE HTML PUBLIC W3C DTD HTML 4 01 Transitional EN gt lt taglib uri WEB INF struts html tld prefix html S gt lt taglib uri WEB INF struts logic tld prefix logic gt lt taglib uri WEB INF struts bean tld prefix bean gt lt S page import com general modelo persistentes Usuarios gt lt S page import com general util Sesion gt lt S page import com general util gt lt html gt lt head gt lt meta http equiv Content Typ
20. this observacion observacion public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Set getProductoses return this productoses public void setProductoses Set productoses this productoses productoses facturacionlsp2 4 58 src gt H com general bo gt HH com general escuchadores gt M com general filtros generales 4 H com general modelo persistentes gt IN Usuarios java 106 package com general modelo persistentes import java util import java util import java util Set Xxx x Usuarios entity l Date HashSet author MyEclipse Persistence Tools 7 public class Usuarios implements java io Serializable Fields private private private private private private Integer idUsuario Roles roles Personas personas String String String Date f descUsuario clave estado privat private private private private
21. public Date getFechalnicio return this fechaInicio public void setFechalnicio Date fechalnicio this fechalnicio fechalnicio public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaFin return this fechaFin public void setFechaFin Date fechaFin this fechaFin fechaFin public String getEstado return this estado public void setEstado String estado this estado estado public String getTelefonoTrabajo return this telefonoTrabajo public void setTelefonoTrabajo String telefonoTrabajo this telefonoTrabajo telefonoTrabajo public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion 52 public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuariolngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Set getFacturases return this facturases public void setFacturases Set facturases this facturases factur
22. sth7 dbh gt prepare sq7 sth7 gt execute oe YFHY HU Script Activar lotes usr bin perl use DBI db DBI mysql facturacionisp 127 0 0 1 username root Spass redes dbh DBI gt connect db username pass sql qq SELECT FROM servicios contratados WHERE estado l AND descripcion_servicio CORREO dbh gt do sql 192 sth dbh gt prepare sq sth gt execute while array sth gt fetchrow_array var 0 contrato array 1 Sip Sarray 8 print SELECT FROM facturas WHERE id contrato Scontrato AND estado ye J print n sq2 qq SELECT FROM facturas WHERE id contrato Scontrato AND estado l dbh gt do sq2 sth1 dbh gt prepare sq2 sth1 gt execute print sth1 print var while array3 sth1 gt fetchrow_array var 1 print var print entra al while if Svar eq 0 print entra if iptables t nat A POSTROUTING o eth0 s Sip 32 j MASQUERADE sq10 qq INSERT INTO nat ip VALUES Sip dbh gt do sq10 sth10 dbh gt prepare sq10 sth10 gt execute dbh DBI gt connect db username pass sq16 qq UPDATE servicios_contratados SET estado A valor_referencia_3 Automatico reactivado WHERE estado l AND id_contrato Scontrato dbh gt do sq16 Ssth16 dbh gt prepare sq16 sth16 gt execute
23. throw new Exception El valor del parametro debe ser numerico para el impuesto de facturas param setObservacion Actualizacion de parametro param setUsuariolngreso Usuarios request getSession g etAttribute Sesion USUARIO getDescUsuario param setFechaActualizacion new Date parameDao attachDirty param DAOUtil commit request getSession setAttribute MENSAJEOK Actualizacion De Parametro Exitoso request getSession setAttribute PAGINA filConfigtacion do return mapping findForward ok catch Exception e DAOUtil rollback e printStackTrace request getSession setAttribute ERRORGENERAL e request getSession setAttribute TITULOERROR Error Actualizacion Parametro return mapping findForward fallo a facturacionlsp2 4 53 src gt M com general bo 8 com general escuchadores gt H com general filtros generales gt MH com general modelo persistentes EB com general struts 4 com general struts action 3 ACambiarClave java 2 ActivarImpuestoAction java 3 ActivarRolAction java 2 ActivarUsuarioAction java 3 ActualizarParametrosAction java 3 ActualizarProductoAction java 15 AniadirOpcionAction java Generated by MyEclipse Struts 145 Template path templates 7java JavaClass vtl F package com general struts action
24. FROM contratos WHERE id contrato Scontrato y dbh gt do sq3 sth3 dbh gt prepare sq3 sth3 gt execute while array3 sth3 gt fetchrow_array nombreplan array3 1 print SELECT FROM productos WHERE descripcion Snombreplan sq4 qq SELECT FROM productos WHERE descripcion nombreplan dbh gt do sq4 sth4 dbh gt prepare sq4 sth4 gt execute while array4 sth4 gt fetchrow_array print TEST datos 0 ip 32 n close TEST nombreplanfile Sarray4 1 8 ruta etc sysconfig cbq Enombreplanfile print more etc sysconfig cbq test gt gt Sruta 191 more etc sysconfig cbq test gt gt Sruta rm rf etc sysconfig cbq test sbin cbq restart dbh DBI gt connect db username pass sq6 qq SELECT FROM servicios contratados WHERE estado R AND valor referencia 3 CORREO AND valor referencia 2 NULL dbh gt do sq6 sth6 dbh gt prepare sq6 sth6 gt execute while array6 sth6 gt fetchrow_array correo array6 8 id_servicio Sarray6 0 id_contrato array6 1 cryptpw crypt correo 14 system useradd c correo s bin nologin p Scryptpw correo sq7 qq UPDATE servicios_contratados SET estado A WHERE estado R AND id_ servicio id_servicio AND valor_referencia_3 CORREO AND id contrat o id_contrato dbh gt do sq7
25. dbh gt do sq3 sth3 dbh gt prepare sq3 sth3 gt execute while array3 sth3 gt fetchrow_array idcontrato array3 0 cuenta array 1 dbh DBI gt connect db username pass sq6 qq SELECT FROM servicios contratados WHERE id contrato Sidcontrato AND descripcion_servicio CORREO dbh gt do sq6 sth6 dbh gt prepare sq6 sth6 gt execute while array6 sth6 gt fetchrow_array ip array6 8 iptables t nat D POSTROUTING o eth0 s Sip 32 j MASQUERADE linea datos 0 ip 32 dbh DBI gt connect db username pass sq6 qq SELECT FROM servicios contratados WHERE id contrato Sidcontrato AND valor referencia 3 CORREO AND valor_referencia_2 l NULL dbh gt do sq6 sth6 dbh gt prepare sq6 sth6 gt execute while array6 sth6 gt fetchrow_array correo array6 8 system userdel rf correo dbh DBI gt connect db username pass sq15 qq SELECT FROM productos WHERE descripcion Scuenta dbh gt do sq15 sth15 dbh gt prepare sq15 sth15 gt execute 201 while array15 sth15 gt fetchrow_array nombrefile array15 18 Sruta etc sysconfig cbq fnombrefile more ruta grep v linea gt etc sysconfig cbq test2 rm rf ruta mv etc sysconfig cbq test2 Sruta dbh DBI gt connect db username pass
26. localtime time 194 values split now print values 1 values 2 values 4 mesmag values 1 f mesmaq eq Jan mes 01 f S5mesmaq eq Feb mes 02 if mesmaq eq Mar mes 03 f S mesmaq eq Apr mes 04 f 6mesmaq eq May mes 05 if 5mesmaq eq Jun Smes 06 if f f f f f i i if 5mesmaq eq Jul mes 07 if 5mesmaq eq Agu mes 8 if Smesmaq eq Sep mes 9 if Smesmaq eq Oct Smes 10 if 6mesmaq eq Nov mes 11 if 6mesmaq eq Dec mes 12 dbh DBI gt connect db username pass sql qq SELECT FROM servicios_contratados WHERE estado A AND descripcion servici CORREO dbh gt do sql sth dbh gt prepare sq sth gt execute Sfecha1 Svalues 4 5mes 01 fecha2 Svalues 4 5mes 5values 2 print Sfecha1 while array sth gt fetchrow_array contrato array 1 ip Sarray 8 print SELECT FROM facturas WHERE id contrato contrato AND estado I AND DATE_FORMAT fecha_factura INTERVAL 5 DAY y m d lt DATE_FORMAT NOW y m d print n sq2 qq SELECT FROM facturas WHERE id contrato Scontrato AND estado I AND DATE_FORMAT fecha_factura INTERVAL 5 DAY y m d lt DATE_FORMAT NOW y m d dbh gt do sq2 sth1 dbh gt prepare sq2 sth1 gt execute while array
27. name actualizarParametrosForm input paginas transacciones seguridad actualizarParametro jsp scope request validate true struts action forward name ok path sdfdfdf redirect true 143 struts action forward name fallo path dsfsd redirect true public class ActualizarParametrosAction extends Action Generated Methods Ef Method execute param mapping param form param request param response return ActionForward A AR E HF F N public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response ActualizarParametrosForm actualizarParametrosForm ActualizarParametrosForm form TODO Auto generated method stub try IE actualizarParametrosForm getValorParametro length lt 1 throw new Exception Debe ingresar un valor para el parametro DAOUtil beginTransaction ParametrosDAO parameDao new ParametrosDAO Parametros param parameDao findByld new Integer actualizarParametrosForm getIdParametro param setValorParametro actualizarParametrosForm getValor Parametro toUpperCase if param getDescripcion equals IVA param getDescripcion equals ICE try Float parseFloat actualizarParametrosForm getValorParamet ro catch Exception e 144
28. nombreUri replaceAll nombreContext F nombreContext replaceAll System out println URI nombreUri System out println CONTEXT nombreContext if sesionWeb null log debug Session Caducada no se puede 18 ingresar a la opcion rere getWriter printin lt script gt top close window open rutalnicial lt script gt if nombreUri toUpperCase equals nombreContext toUpperCase System out printin La sesion es nueva continuar log debug La sesion es nueva continuar else nombrePaginaActual nombreUri substring nombreContext length System out printin La sesion es antigua log debug Validacion de usuario i if nombrePaginaActual toUpperCase indexOf LOGIN 1 nombrePaginaActual toUpperCase indexOf ERROR System out println Es el login continuar log debug Es el login continuar rere getWriter println lt script gt top close window open rutalnicial lt script gt else Usuarios 1 usuario Usuarios sesionWeb getAttribute Sesion USUARIO if 1l usuario null log debug El usuario no esta logoneado por favor reingrese rere getWriter println lt script gt top close window open rutaInicial lt script gt 19 System
29. this usuariolngreso usuariolngreso Property accessors public Integer getIdDetallePago return this idDetallePago public void setIdDetallePago Integer idDetallePago this idDetallePago idDetallePago public FormasPagos getFormasPagos return this formasPagos public void setFormasPagos FormasPagos formasPagos this formasPagos formasPagos TI public Facturas getFacturas return this facturas public void setFacturas Facturas facturas this facturas facturas public Double getValor return this valor public void setValor Double valor this valor valor public String getDescripcion return this descripcion public void setDescripcion String descripcion this descripcion descripcion public String getReferenciaBancaria return this referenciaBancaria public void setReferenciaBancaria String referenciaBancaria this referenciaBancaria referenciaBancaria public String getNumeroTransaccion return this numeroTransaccion public void setNumeroTransaccion String numeroTransaccion this numeroTransaccion numeroTransaccion public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro 78 public void setFechaRegistro Date fechaReg
30. toString equals roll getId Rol toString amp amp opcRoles getEstado equals A asignadas opcionesAsignadas add opcion else no asignadas opcionesNoAsignadas add opcion Debo sumar las opciones que no estan en la de opciones roles List totalOpciones opcDao findByEstado A Iterator totalOpcionesSin totalOpciones iterator Set opcionesRoll roll getOpcionesRoleses j Iterator totalOpcl opcionesRol iterator while totalOpcionesSin hasNext Opciones opcionSin Opciones totalOpcionesSin next try if opcionSin getOpciones getIdOpcion toString equals ope getIdOpcion toString if opcionSin getOpcionesRoleses size 0 opcionesNoAsignadas add opcionSin 30 Op e new Cc request getSession opcionesAsignadas request getSession opcionesNoAsignadas catch Exception eFin request getSession setAttribute OPC_ENC D AOUtil commit setAttribute OPC_MOD_ASIG setAttribute OPC MOD NO ASIG eturn mapping findForward ok catch Exception e e printStackTrace DAOUtil rollback request getSession setAttribute TITULOERROR Buscar Opciones request getSession setAttribute ERRORGENERAL Exception principal
31. 1 usuario setCambioClave S 1 usuario setClave UtilCryptography encriptar ps_ claveNueva 1l_usuario setActualizarClave N UsuariosDAO 1_uHome new UsuariosDAO 1_uHome attachDirty 1_usuario DAOUtil commit return 1 usuario catch Exception e DAOUtil rollback throw e private Usuarios validarLogin String ps user String ps_password throws Exception InvalidKeyException InvalidKeySpecException NoSuchAlgorithmException NoSuchPaddingException InvalidAlgorithmParameterException IllegalBlockSizeException BadPaddingException UnsupportedEncodingException ExcepcionLogicaNegocio 13 CONTIENE LA VALIDACION DEL USER Y DEL PASSWORD UsuariosDAO 1_home new UsuariosDAO Usuarios l_usuario Usuarios l_home findByUser ps_user ps_password ps_password toUpperCase trim No debo hacerle upper case a la clave ps password UtilCryptography encriptar ps password if l_usuario null throw new Exception No se encontro el usuario ps_user toUpperCase registrado en el sistema if 1l_usuario getEstado equals I throw new Exception El usuario Wek ps_user toUpperCase se encuentra en un estado invalido registrado en el sistema if l_usuario getClave equals ps passwor
32. ACCION accion request getSession setAttribute IDENTIFICACION datoIdentificacion request getSession setAttribute TIPO aux request getSession setAttribute TITULOERROR null request getSession setAttribute ERRORGENERAL null if datoldentificacion trim equals throw new Exception Ingrese una identificaci n para realizar la busqueda if datoldentificacion trim length lt 10 throw new Exception La identificacion debe tener mas de 10 caracteres HashMap mapa Operaciones validaDeudaCliente datoIdentificacion Double deuda Double mapa get DEUDA double deudafinal deuda doubleValue String observacion String mapa get OBSERVACION if deudafinal gt 0 throw new Exception No se puede crear el contrato motivo observacion toUpperCase 24 DAOUtil beginTransaction PersonasDAO personaDao new PersonasDAO Personas persona personaDao findByPropert yUnique personaDao CEDULA datoIdentificacion if datoIdentificacion trim equals ValidacionesVarias validarDocumento datoIdentificaci on request getSession setAttribute IDENTPER datolde ntificacion if persona null
33. DetallesFacturas persistentInstance log debug deleting DetallesFacturas instance try getSession delete persistentInstance log debug delete successful 72 catch RuntimeException re log error delete failed re throw re public DetallesFacturas findById java lang Integer id log debug getting DetallesFacturas instance with id id try DetallesFacturas instance DetallesFacturas getSession get com general modelo persistentes DetallesFacturas id return instance catch RuntimeException re log error get failed re throw re public List findByExample DetallesFacturas instance log debug finding DetallesFacturas instance by example try List results getSession createCriteria com general modelo persistentes DetallesFacturas add Example create instance list We log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String propertyName Object value log debug finding DetallesFacturas instance with property 73 propertyName value V value try String queryString from DetallesFacturas as model where model propertyName Query queryObject
34. Personas personas this personas personas this estado estado String estado 50 full constructor public Clientes Personas personas String direccionEntregaFact Date fechalnicio Date fechaRegistro Date fechaFin String estado String telefonoTrabajo String observacion Date fechaActualizacion String usuario Ingreso Set facturases Set contratoses his personas personas his direccionEntregaFact direccionEntregaFact his fechalnicio fechalnicio his fechaRegistro fechaRegistro his fechaFin fechaFin his estado estado is telefonoTrabajo telefonoTrabajo his observacion observacion his fechaActualizacion fechaActualizacion his usuariolngreso usuariolngreso his facturases facturases his contratoses contratoses tt ttt et et ct ct ct ct ct J Property accessors public Integer getIdCliente return this idCliente public void setIdCliente Integer idCliente this idCliente idCliente public Personas getPersonas return this personas public void setPersonas Personas personas this personas personas public String getDireccionEntregaFact return direccionEntregaFact public void setDireccionEntregaFact String direccionEntregaFact this direccionEntregaFact direccionEntregaFact 51
35. obtener todas las opciones activas List opcionesActivas opcDao findByEstado A Iterator opcActivas opcionesActivas iterator Vector opcionesAsignadas new Vector Vector opcionesNoAsignadas new Vector 28 Set opcionesDelModulo opc getOpcioneses Barrerme los registros del modulo Iterator iter opcionesDelModulo iterator boolean guardaAsigando false while iter hasNext Opciones opce Opciones iter next Set opcRoles opce getOpcionesRoleses Iterator ter2 opcRoles iterator guardaAsigando false while ter2 hasNext OpcionesRoles oprR OpcionesRoles ter2 next if oprR getRoles getIdRol toString equals ro11 getIdRol toString Debo asignarlo a los asignados guardaAsigando true if guardaAsigando opcionesAsignadas add opce else opcionesNoAsignadas add opce while totalOpc hasNext OpcionesRoles opcRoles OpcionesRoles totalOpc next Opciones opcion opcRoles getOpciones if opcion getOpciones null if opcion getOpciones getIdOpcion toString equals opc ge tIdOpcion toString 29 Aqui estoy sacando las opciones que estan asigandas al rol y que tienen como modulo padre a la opcion que seleccion if opcRoles getRoles getIdRol
36. return this observacion public void setObservacion String observacion this observacion observacion public Date getFechaActualizacion 44 return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuariolngreso return this usuariolngreso public void setUsuarioIngreso String usuarioIngreso this usuarioIngreso usuariolngreso public Set getContratoses return this contratoses public void setContratoses Set contratoses this contratoses contratoses 4 H com general modelo persistentes J BaseHibernateDAO java gt b Y CiclosFacturaciones java gt 4 CiclosFacturacionesDAO java package com general modelo persistentes FECHA 20 06 2009 AUTOR GRUPO 3 COMENTARIO CLASE DAO QUE PERMITE ACCEDER A LOS RTEGITRSO DE LA TABLA CICLOS_FACTURACIONES x x import java util Date import java util List import java util Set import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode 45 import org hibernate Query import org hibernate criterion Example Xxx x A data access object DAO providing persistence and search s
37. sq6 qq UPDATE contratos SET estado I WHERE estado X AND id contrato Sidcontrato dbh gt do sq6 sth6 dbh gt prepare sq6 sth6 gt execute
38. titulo gt CAMBIAR CLAVE lt td gt lt tr gt lt tr gt lt td class etiquetaForma width 32 gt lt bean message key etiquetas cambiarClave user gt lt td gt lt td class detalleForma gt lt html text property user maxlength 20 size 30 readonly true onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off styleClass cajaTexto value lt 1_usuario getDescUsuario gt gt lt html text gt lt td gt lt tr gt lt tr gt lt td class etiquetaForma width 35 gt lt bean message key etiquetas cambiarClave claveActual gt lt td gt lt td class detalleForma gt lt html password property claveActual maxlength 20 size 30 onfocus cambiarEstiloCajaTextoPass event on onblur cambiarEstiloCajaTextoPass event off styleClass cajaTextoPass onchange validarClaveActual this gt lt html password gt lt td gt lt tr gt SUL lt td class etiquetaForma width 35 gt lt bean message key etiquetas cambiarClave claveNueva gt lt td gt lt td class detalleForma gt lt html password property claveNueva maxlength 20 size 30 onfocus cambiarEstiloCajaTextoPass event on 181 onblur cambiarEstiloCajaTextoPass event off styleClass cajaTextoPass gt lt html password gt lt td gt lt tr gt lt tr gt lt td class etiquetaFor
39. 001 valor false throw new Exception El la empresa del sector privado debe terminar con 001 if natural true if digitoVerificador d10 valor false throw new Exception El de cedula de la persona natural es incorrecto if numero length gt 10 ruc de ruc de numero amp amp numero substring 10 longitud equals TOOT valor false throw new Exception El la persona natural debe terminar con 001 catch Exception e valor false throw new Exception Error e getMessage return valor ruc de e WebRoot gt codebase gt css gt imagenes amp img is gt logosEmpresa GC META INF i gt paginas gt reportes gt Scripts gt swf gt WEB INF if flash html gP index html 4 indexLjsp 4 loginPrincipal jsp H MyHtmi html J reportunoe jsp 169 x hibernate reveng xml ao ao page language java page taglib uri WEB INF struts html tld prefix htmi 55 NA ANA ao OOO ao taglib uri WEB INF struts A ao Pantal a pricipal permit Encoding ISO 8859 1 gt taglib uri WEB INF struts logic tld prefix logic gt bean tld prefix bean gt l acceso a la aplicacion Variabl e de error en caso de existir Exceptio
40. 8 Sarray2 9 array2 1 1 fecha DATE_FORMAT fecha_registro INTERVAL 5 DAY y m d open MAIL usr sbin sendmail t Mail Header print MAIL To to n print MAIL From from n print MAIL Subject subject n n Mail Body print MAIL Estimado Cliente nombre print MAIL n n print MAIL Le recordamos que su factura ya fue emitida con un valor de signo print MAIL valor print MAIL n print MAIL la misma que puede ser cancelada en cualquiera de nuestras oficina hasta print MAIL n print MAIL 5 dias despues de la fecha de la factura print MAIL en que se realiza el corte automatico print MAIL n print MAIL Gracias print MAIL n print MAIL Att print MAIL n print MAIL razonsocial close MAIL print lt html gt lt head gt lt title gt title lt title gt lt head gt n lt body gt n n HTML content let use know we sent an email print lt h1 gt title lt h1 gt n print lt p gt A message has been sent from from to to print n n lt body gt lt html gt Script Renuncia usr bin perl 200 use DBI datos RULE db DBl mysd facturacionisp 127 0 0 1 username root Spass redes print SELECT FROM contratos WHERE id contrato contrato dbh DBI gt connect db username pass sq3 qq SELECT FROM contratos WHERE estado X
41. Integer idDetalle private private private private private private private private private private private private private Productos productos Facturas facturas String descripcion Double valorUnitario Integer cantidad Double subtotal Double valorIva Double valorIce String estado String observacion Date fechaRegistro String usuariolngreso Date fechaActualizacion Constructors default constructor public DetallesFacturas minimal constructor public DetallesFacturas Productos productos Facturas facturas Integer cantidad String estado this productos productos this facturas facturas this cantidad cantidad this estado estado full constructor public DetallesFacturas Productos productos Facturas facturas String descripcion Double valorUnitario Integer cantidad Double subtotal Double valorIva Double valorIce String estado String observacion Date fechaRegistro usuarioIngreso String 68 Date fechaActualizacion this productos productos this facturas facturas this descripcion descripcion this valorUnitario valorUnitario this cantidad cantidad this subtotal subtotal this valorIva valorlva this valorIce valorlce this estado estado this observacion observacion this fechaRegistro fechaRegistro this usuariolngreso usuariolngreso this fechaAct
42. by property name failed re throw re public List findByDescripcionCiclo Object descripcionCiclo return findByProperty DESCRIPCION_CICLO descripcionCiclo public List findByEstado Object estado return findByProperty ESTADO estado public List findByObservacion Object observacion return findByProperty OBSERVACION observacion public List findByUsuarioIngreso Object usuarioIngreso return findByProperty USUARIO_INGRESO usuariolngreso public List findAll log debug finding all CiclosFacturaciones instances try String queryString from CiclosFacturaciones Query queryObject getSession createQuery queryString return queryObject list 48 catch RuntimeException re log error find all failed re throw re public CiclosFacturaciones merge CiclosFacturaciones detachedInstance log debug merging CiclosFacturaciones instance try CiclosFacturaciones result CiclosFacturaciones getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re public void attachDirty CiclosFacturaciones instance log debug attaching dirty CiclosFacturaciones instance try
43. claveNuevalngresada f alert Ingrese primero la clave nueva formaCambioClave claveNueva value formaCambioClave confirmacionClaveNueva value return if claveConfNuevalngresada claveNuevalngresada alert Las claves nuevas no concuerdan por favor ingresarlas correctamente object value formaCambioClave claveNueva value return function verificarInicial var inicial lt lsInicio gt if inicial S window open lt request getContextPath gt trabajo do TRABA JO lt script gt lt head gt lt body topmargin 0 bottommargin 0 leftmargin 0 rightmargin 0 onunload verificarInicial gt lt ao if error null 180 5 gt lt script type text javascript gt window showModalDialog lt request getContextPath gt error d o blank dialogheight 20 lt script gt lt 2 2 gt lt html form action cambiarClave onsubmit return validateFormaCambioClave this gt lt table border 0 width 100 height 80 gt lt tr align center valign middle gt lt td gt lt table align center width 85 cellspacing 1 cellpadding 1 class tabla gt lt tr gt lt td colspan 4 class cabeceraForma gt Administracion De Claves lt td gt lt tr gt lt tr height 5 gt lt td colspan 4 gt lt td gt lt tr gt lt tr gt lt td colspan 2 class
44. connect db username pass sql qq SELECT FROM productos WHERE estado C dbh gt do sal sth dbh gt prepare sql sth gt execute while Oarray sth gt fetchrow_array dbh2 DBI gt connect db username Spass sql2 qq SELECT FROM numeros ORDER BY id DESC dbh2 gt do sql2 sth2 dbh2 gt prepare sql2 sth2 gt execute array1 sth2 gt fetchrow_array valor array1 0 valor1 valor 1 dbh3 DBI gt connect db username Spass sql3 qq INSERT INTO numeros id VALUES valor1 dbh3 gt do sql3 189 Sidpro array 0 nombre array 2 valormax array 7 nombrefile cbq 00 Svalor nombre Sruta gt etc sysconfig cbq nombrefile print ruta wei valormax 10 Sweifinal1 int wei open PLANES ruta die No pudo abrirse S print PLANES Sdatos 0 n print PLANES datos 1 valormax k n print PLANES datos 2 weifinal1 k n print PLANES datos 3 n close PLANES dbh DBI gt connect db username pass sql4 qq UPDATE provisiona activacion plan SET estado A fecha_actualiza fecha2 WHERE codi_plan 5nombre dbh gt do sql4 sth4 dbh gt prepare sql4 sth4 gt execute dbh DBI gt connect db username pass sql5 qq UPDATE productos SET estado A fecha_actualizacion fecha2 nombrefi
45. e Exception action action action action Exception letRequest letResponse Action ActionForm ActionForward ActionMapping Exception Exception 37 import com general model import com general model import com general modelo persistentes RolesDAO import com general modelo persistentes Usuarios import com general modelo persistentes UsuariosDAO import com general struts form IngresoUsuarioForm import com general util DAOUtil import com general util Sesion import com general util UtilCryptography persistentes Personas persistentes PersonasDAO O O O O MyEclipse Struts Creation date 08 29 2009 XDoclet definition struts action path ingresoUsuario name ingresoUsuarioForm input paginas transacciones seguridad ingresoUsuario jsp scope request validate true 8 struts action forward name procesoFallido path paginas transacciones seguridad ingresoUsuario jsp redirect true struts action forward name procesoExitoso path sdsdsd redirect true Ng public class IngresoUsuarioAction extends Action Generated Methods 7 A AR XA Xx Method execute param mapping param form param request param response return ActionForward A HF XA N public ActionForward execute ActionMapping mapping ActionForm form HttpServlet
46. failed re throw re public List findByCuenta Object cuenta return findByProperty CUENTA cuenta public List findByEstado Object estado return findByProperty ESTADO estado public List findByPlazo Object plazo return findByProperty PLAZO plazo public List findByObservacion Object observacion return findByProperty OBSERVACION observacion 65 D ublic List findByUsuariolngreso Object usuariolngreso return findByProperty USUARIO_INGRESO usuariolngreso public List findByValorReferencial Object valorReferencial return findByProperty VALOR_REFERENCIA 1 valorReferencial public List findAll log debug finding all Contratos instances try String queryString from Contratos Query queryObject getSession createQuery queryString return queryObject list catch RuntimeException re log error find all failed re throw re public Contratos merge Contratos detachedInstance log debug merging Contratos instance try Contratos result Contratos getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re public void attachDirt
47. getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Set getContratoses return this contratoses public void setContratoses Set contratoses this contratoses contratoses public Set getEmpleadoses 87 return this empleadoses public void setEmpleadoses Set empleadoses this empleadoses empleadoses public Set getFacturases return this facturases public void setFacturases Set facturases this facturases facturases 4 facturacionlsp2 4 58 src EB com general bo E3 com general escuchadores 48 com general filtros generales 4 FH com general modelo persistentes J EmpresasDAO java package com general modelo persistentes import java util Date import java util List import java util Set import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode import org hibernate Query import org hibernate criterion Example Xxx x A data access object DAO providing persistence and search support for Empresas entities Transaction control of the save update and delete operations can directly support Spring container managed transactions or they can be augmented to handle user managed Spring transactions Each of these
48. idCiclo String observacion String user throws Exception 34 TODO Auto generated method stub Productos prod Productos planes elementAt 0 Date fecha new Date SimpleDateFormat lsdf new SimpleDateFormat ddMMyyyyhhmmss Contratos cont new Contratos ContratosDAO contDao new ContratosDAO CiclosFacturacionesDAO cicloDAO new CiclosFacturacionesDAO CiclosFacturaciones ciclo cicloDAO findById new Integer idCiclo if ciclo null throw new Exception No se encontro el ciclo idCiclo en el sistema EmpleadosDAO empDao new EmpleadosDAO cont setCiclosFacturaciones ciclo cont setClientes cliente cont setCuenta prod getDescripcion toUpperCase cont setEmpleados null cont setEstado R contrato que no tiene servicios activos primera vez cont setFechaInicio new Date cont setFechaRegistro new Date Calcular la fecha fin fecha inicio plazo PlazosPlznesDAO plazoDao new PlazosPlznesDAO String plazo plazoDao findByld prod getPlazo getDescPlazo cont setPlazo plazo Calendar calendar Calendar getInstance calendar add Calendar MONTH gt Integer parselnt plazo cont setFechaFin calendar getTime cont setObservacion observacion toUpperCase Obtener el plazo luego el precio cont setPrecioPlan
49. jakarta apache org struts tags bean prefix bean gt lt taglib uri http jakarta apache org struts tags html prefix html gt lt page import com general modelo persistentes gt lt Exception error 174 Exception request getSession getAttribute ERRORGENERAL Personas persona Personas request getSession getAttribute PERSONAENCONTRADA String datolden String request getSession getAttribute IDENTIFICACION String usuario String request getSession getAttribute DESCUSUARIO request getSession setAttribute PERSONAENCONTRADA null request getSession setAttribute IDENTIFICACION null request getSession setAttribute DESCUSUARIO null datolden datolden nul1 datolden usuario usuario null usuario String nombreCompleto String idPersona if persona null nombreCompleto persona getPrimerNombre toUpperCase persona getSegundoNombre toUpperCase persona getApellidoPaterno toUpperCase persona getApellidoMaterno toUpperCase idPersona persona getIdPersona toString j if datoIden equals datolden persona getCedula datoIden datoIden null datoIden if datoIden equals
50. java io UnsupportedEncodingException import java security InvalidAlgorithmParameterException import java security InvalidKeyException import java security NoSuchAlgorithmException import java security spec AlgorithmParameterSpec import java security spec InvalidKeySpecException import java security spec KeySpec import javax crypto BadPaddingException import javax crypto Cipher import javax crypto IllegalBlockSizeException import javax crypto NoSuchPaddingException import javax crypto SecretKey import javax crypto SecretKeyFactory import javax crypto spec PBEKeySpec import javax crypto spec PBEParameterSpec public class UtilCryptography private static byte SALT_BYTES byte OxA9 byte 0x9B byte 0xC8 byte 0x32 byte 0x56 byte 0x35 byte OxE3 byte 0x03 he private static int ITERATION_COUNT 19 private final static String CLAVE REALMSOFT2006DTO1984 161 Invalid public static St KeyException NoSuchAlgorithmException ring encriptar String Nos str InvalidKeySpecException uchPaddingException throws nvalidAlgorithmParameterException IllegalBlockSizeException BadPaddingException UnsupportedEncodingException return encriptar CLAVE str public static String encriptar String passPhrase String str throws InvalidKeySpecException NoSu
51. lt request getContextPath gt css disenioGeneral css type text css gt lt link gt lt script type text javascript language Javascript1 1 src lt request getContextPath gt js validacionesStruts js gt lt scrip t gt lt html javascript formName loginForm staticJavascript false gt lt head gt lt script type text javascript gt function habilitarEnter e 171 fuincion para habilitar el enter var tecla event keyCode if parseInt tecla 13 validarCampos function validarCampos 7 lt script gt lt if errorl null if errorl getMessage null 3 gt lt script type text javascript gt permite presentar el error con el dialogo window showModalDialog lt request getContextPath gt error do _blank dialogheight 20 lt script gt c3 AQ gt x creacion de la forma y el cuerpo de la pagina gt lt body onkeypress habilitarEnter event bgcolor 7EAF39 gt lt Con esto se hace referencia al action del controlador que se va a usar 5 lt html form action login focus usuario onsubmit return validateLoginForm this gt lt table width 100 border 0 cellpadding 0 cellspacing 0 bgcolor 7EAF39 height 30 gt lt tr gt lt td width 111 height 60 gt amp nbsp lt td gt lt td width 121 gt nbsp lt td
52. methods provides additional information for how to configure it for the desired type of transaction control 88 see com general modelo persistentes Empresas author MyEclipse Persistence Tools Z public class EmpresasDAO extends BaseHibernateDAO private static final Log log LogFactory getLog EmpresasDAO class property constants public static final String RAZON_SOCIAL razonSocial public static final String RUC ruc public static final String DIRECCION_LOGO direccionLogo public static final String ESTADO estado public static final String OBSERVACION observacion public static final String USUARIO_INGRESO usuarioIngreso public void save Empresas transientInstance log debug saving Empresas instance try getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re public void delete 1 throw re log debug deleting try catch Empresas persistentInstance Empresas instance getSession delete persistentInstance log error del throw re public Empresas findBy log debug getting id try Empresas getSession get instance Id java lang Empresas instance wit log debug delete su
53. new Double prod get TarifaBasica doubleValue cont setUsuarioIngreso user cont setValorReferencial Cantidad Servicios 35 Productos planes elementAt 0 getTiposProdcutos getCaon tidadMaxima contDao save cont ServiciosContratadosDAO servDao new ServiciosContratadosDAO Registrar los servicios por cada plan uno mas para el correo for int i 0 1 lt prod getTiposProdcutos getCaontidadMaxima intValue i ServiciosContratados serv new ServiciosContratados serv setContratos cont serv setDescripcionServicio prod getDescripcion serv setEstado R Reservado serv setFechaRegistro new Date serv setObservacion observacion serv setProductos prod serv setUsuarioIngreso user serv setValorReferencia3 PLAN INTERNET serv setFechalnicio new Date servDao save serv String referencia persona getPrimerNombre persona getSegundoNombre persona getApellidoPaterno persona getApellidoMa terno Generar referencia ojo con el usuario asi como lo haces para crear el usuario referencia lt persona getPrimerNombre substring 0 1 persona getApellidoPaterno j List referenci servDao findByValorReferencia2 referencia if referenci size 0 Ley ae dg ServiciosContratados correo new 36 ServiciosC
54. out println Fin Ejecucion De Filtro General this getClass new Date chain doFilter re rere catch IOException e TODO Auto generated catch block e printStackTrace public void destroy this filterConfig null s H com general struts action i ACambiarClave java D ActivarlmpuestoAction java 3 ActivarRolAction java D ActivarUsuarioAction java J ActualizarParametrosAction java Generated by MyEclipse Struts Template path templates java JavaClass vtl Ef package com general struts action import java util Date import Javax servlet http HttpServletRequest import jJavax servlet http HttpServletResponse import org apache struts action Action import org apache struts action ActionForm import org apache struts action ActionForward import org apache struts action ActionMapping import com general modelo persistentes Parametros import com general modelo persistentes ParametrosDAO import com general modelo persistentes Usuarios import com general struts form ActualizarParametrosForm import com general util DAOUtil import com general util Sesion Xxx x MyEclipse Struts x Creation date 08 02 2007 20 XDoclet definition struts action path actualizarParametros name actualizarParametrosForm input paginas transacciones seguridad actualizarParametro jsp sc
55. public String getEmail return email Xxx 159 Set the email param email The email to set wy public void seti this email Email String email email Xxx x Returns the pasaporte return String a public String getPasaporte return pasaporte Xxx x Set the pasaporte x param pasaporte The pasaporte to set ET public void setPasaporte String pasaporte this pasaporte pasaporte Xxx x Returns the direccion x return String public String getDireccion return direccion Xxx x Set the direccion x param direccion The direccion to set x public void setDireccion String direccion this direccion direccion Xxx x Returns the telefono x return String public String getTel return telefono lefono Xxx x Set the telefono 160 param telefono The telefono to set KH public void setTelefono String telefono this telefono telefono public String getTipoPersona return tipoPersona public void setTipoPersona String tipoPersona this tipoPersona tipoPersona 4 8 com general util J ActionExportlasperReportjava I ActionMessagesUtil java IN CargarArchivo java J Configuracion java package com general util import Java io IOException import
56. public static observacion public static usuariolngreso ENTR RECC String D ON EGA FACT E EL estado EFONO_ TRABAJO OBS ERVAC final ON String USUAR O NGR final ESO String ublic void save Clientes transientInstance log debug saving Clientes instance try P getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete Clientes persistentInstance 54 log debug deleting Clientes instance try getSession delete persistentInstance log debug delete successful catch RuntimeException re log error delete failed re throw re public Clientes findById java lang Integer id log debug getting Clientes instance with id id try Clientes instance Clientes getSession get com general modelo persistentes Clientes id return instance catch RuntimeException re log error get failed re throw re public List findByExample Clientes instance log debug finding Clientes instance by example try List results getSession createCriteria com general modelo persistentes Clientes add Example create instance list We log debug f
57. 2 sth1 gt fetchrow_array numero_factura array2 1 idfactura array2 0 print numero_factura print INSERT INTO inactivacion servicios ip maquina estado VALUES 195 Sip TY print n sq3 qq INSERT INTO inactivacion servicios ip maquina estado VALUES Sip 1 dbh gt do sq3 Ssth2 dbh gt prepare sq3 sth2 gt execute iptables t nat D POSTROUTING o eth0 s ip 32 j MASQUERADE sq13 qq DELETE FROM nat WHERE ip ip dbh gt do sq13 sth13 dbh gt prepare sq13 sth13 gt execute dbh DBl gt connect db username pass sql11 qq SELECT FROM nat WHERE ip Sip dbh gt do sql1 1 sth11 dbh gt prepare sql1 1 sth1 1 gt execute while array11 sth11 gt fetchrow_array sql12 qq UPDATE servicios_contratados SET estado A WHERE estado R AND id_servicio servicios AND id contrato contrato dbh gt do sql12 sth12 dbh gt prepare sql1 2 sth1 2 gt execute print UPDATE facturas SET estado C WHERE id contrato contrato AND estado l AND DATE_FORMAT fecha_factura y Ym d lt DATE_FORMAT NOW INTERVAL 5 DAY y m d print n sq3 qq UPDATE facturas SET estado C WHERE id contrato Scontrato AND estado I AND DATE_FORMAT fecha_factura y Y m d lt DATE_FORMAT NOW INTERVAL 5 DAY y m d db
58. 6 if error null 375 lt script type text Javascript 5 window showModalDialog lt request getContextPath gt error do blank dialogheight 20 lt script gt lt gt lt html form action ingresoUsuario gt lt table align center width 85 cellspacing 1 cellpadding 1 class tabla gt lt tr gt lt td colspan 4 class cabeceraForma gt Creacion De Usuarios lt td gt lt tr gt lt tr height 5 gt lt td colspan 4 gt lt td gt lt tr gt lt tr gt lt td colspan 4 class titulo gt amp nbsp Datos Usuario lt td gt lt tr gt lt tr gt lt td class etiquetaForma width 20 gt Cedula lt td gt lt td class detalleForma gt lt html text property cedula value lt datoldens gt onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off onchange validarSiNumero this value this styleClass cajaTexto gt lt html errors jproperty descripcionRol gt amp nbsp lt img src lt request getContextPath gt imagenes kedit png onclick buscarCedula cedula value alt Buscar width 20px height 20px align left border 1 hspace 0 vspace 0 gt lt img gt lt td gt lt td class etiquetaForma width 20 gt Nombre Completo lt td gt lt td class detalleForma width 30 gt lt html textarea property nombreCompleto value l
59. 8 src gt AH com general bo FH com general escuchadores gt M com general filtros generales gt A com general modelo persistentes EB com general struts 4 com general struts action gt 1 ACambiarClave java package com general struts action import javax servlet http HttpServletRequest import jJavax servlet http HttpServletResponse import org apache struts action Action import org apache struts action ActionForm import org apache struts action ActionForward import org apache struts action ActionMapping import com general bo import com general modelo persistentes Usuarios import com general struts form FCambioClave import com general util DAOUtil public class ACambiarClave extends Action public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response throws Exception FCambioClave 1_f FCambioClave form try 139 LoginBO 1_bo new LoginBO Usuarios user 1 bo cambiarClave l f getUser 1 f getClaveActual 1_f getCl aveNueva request getSession setAttribute USUARIO user request getSession setAttribute MENSAJEOK Cambio De Clave Realizado Con Exito return mapping findForward okCambiarClave catch Exception e DAOUtil rollback e printStackTrace request getSession setAttribute TITULOERROR Inactivac
60. CION descripcion public static final String REFERENCIA_BANCARIA referenciaBancaria public static final String NUMERO_TRANSACCION numeroTransaccion public static final String ESTADO estado public static final String OBSERVACION observacion public static final String USUARIO_INGRESO usuariolngreso public void save DetallesPagos transientInstance log debug saving DetallesPagos instance try getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete DetallesPagos persistentInstance log debug deleting DetallesPagos instance try getSession delete persistentInstance log debug delete successful catch RuntimeException re log error delete failed re throw re 80 public DetallesPagos findById java lang Integer id log debug getting DetallesPagos instance with id ot aid try DetallesPagos instanc DetallesPagos getSession get com general modelo persistentes DetallesPagos id return instance catch RuntimeException re log error get failed re throw re public List findByExample DetallesPagos instance log debug finding DetallesPa
61. Constructors String String chaRegistro observacion usuariolngreso Date fechaActualizacion Set loginUsuarioses new HashSet 0 private String cambioClave public String getCambioClave return cambioClave public void setCambioClave String cambioClave this cambioClave cambioClave default constructor public Usuarios 107 minimal constructor public Usuarios Roles roles Personas personas String descUsuario String clave String estado this roles roles this personas personas this descUsuario descUsuario this clave clave this estado estado full constructor public Usuarios Roles roles Personas personas String descUsuario String clave String estado Date fechaRegistro String observacion String usuariolngreso Date fechaActualizacion Set loginUsuarioses his roles roles his personas personas his descUsuario descUsuario his clave clave is estado estado his fechaRegistro fechaRegistro his observacion observacion his usuariolngreso usuariolngreso his fechaActualizacion fechaActualizacion his loginUsuarioses loginUsuarioses Gh Gh Gh Gh chk Gh ir J Property accessors public Integer getIdUsuario return this idUsuario public void setIdUsuario Integer idUsuario this idUsuario idUsuario public Roles getRoles
62. Errort return mapping findForward getMessage 7 fal Lory Generated by MyEclipse Struts path templates java JavaClass vtl Template El package com import java import java import java import java import java import j import j import org import org import org import org gener text uta util uE Te util al struts action SimpleDateFormat Calendar Date List Vector avax servlet http HttpServ apache apache apache apache letRequest javax servlet http HttpServ letResponse struts action Action struts action ActionForm struts action ActionForward struts action ActionMapping 31 import com general modelo persistentes CiclosFacturaciones import com general modelo persistentes CiclosFacturacionesDAO import com general modelo persistentes Clientes import com general modelo persistentes Contratos import com general modelo persistentes ContratosDAO import com general modelo persistentes EmpleadosDAO import com general modelo persistentes Personas import com general modelo persistentes PlazosPlznesDAO import com general modelo persistentes Productos import com general modelo persistentes ServiciosContratados import com general modelo persistentes ServiciosContratadosDAO import com general modelo persistent
63. Ml UNIVERSIDAD DE GUAYAQUIL Facultad de Ciencias Matematicas y Fisicas Carrera de Ingenier a en Sistemas Computacionales Sistema de Facturaci n para ISP v a Web PROYECTO DE GRADO CURSO DE GRADUACI N Previo a la Obtenci n del T tulo de INGENIERO EN SISTEMAS COMPUTACIONALES AUTORES S nchez Caicedo Bertha Ver nica Cruz Rosales Diana Elizabeth Ter n Ronquillo Pedro Pablo GUAYAQUI L ECUADOR A o 2010 Ml UNIVERSIDAD DE GUAYAQUIL Facultad de Ciencias Matem ticas y F sicas Carrera de Ingenier a en Sistemas Computacionales Sistema de Facturaci n para ISP v a Web PROYECTO DE GRADO CURSO DE GRADUACI N Previo a la Obtenci n del T tulo de INGENIERO EN SISTEMAS COMPUTACIONALES AUTORES S nchez Caicedo Bertha Ver nica Cruz Rosales Diana Elizabeth Ter n Ronquillo Pedro Pablo GUAYAQUI L ECUADOR A o 2010 INDICE GENERAL CAPITULO Wisc s cass isha tas apis ii 4 Te Mana T CMIcCO 0540 225022080 A eects Ae eas 4 Aga Tan Koto LU ela ON AA ana 4 1 2 Objetivos Generales del Sistema 1 210000777 7aaan 4 1 3 Objetivos especifico S ei 2228222 AA ana naia amang 5 CAPITULO Daanan kpa aa AA 7 2 Contenido TECMICO nl aaa A u SAR RA Gen Aang 7 2 1Reglas del Negogl Oma ANAL E da 7 CAPITULO Sada aNG AALANGAN NG GALA 9 3 Herramientas y configuraciones 11 9 31 MyEc AA 9 3 2 OMC AA 10 ER ati ETE NTE N Ri td SINGT SS 11 CAPITULO Asi A a 12 JA C dig
64. ND descripcion servicio CORREO dbh gt do sq16 sth16 dbh gt prepare sq16 sth16 gt execute Script Mail 197 usr bin perl print Content type text html n n use DBI db DBl mysq l facturacionisp 127 0 0 1 username root Spass redes Stitle Factura del Mes Ssubject Factura del Mes signo a dominio bemusoft com now localtime time values split now print values 1 values 2 values 4 mesmag values 1 if if if if if if if if if if if if mesmaq eq Jan mes 1 print no debio entrar mesmag eq Feb mes 2 Smesmag eq Mar mes 3 mesmagq eq Apr mes 4 mesmaq eq May mes 5 mesmaq eq Jun mes 6 mesmaq eq Jul mes 7 mesmaq eq Agu mes 8s mesmaq eq Sep mes 9 mesmag eq Oct Smes 10 mesmaq eq Nov Smes 11 Smesmagq eq Dec Smes 12 ee A A Sfecha1 Svalues 4 5mes 05 Sfecha2 Svalues 4 5mes Svalues 2 dbh DBI gt connect db username pass sq5 qq SELECT FROM empresas dbh gt do sq5 sth5 dbh gt prepare sq5 sth5 gt execute while array5 sth5 gt fetchrow_array Srazonsocial array5 1 print SELECT FROM facturas WHERE estado M AND DATE FORMAT fecha factura y m d DATE_FORMAT NOW y Yom d 198 pr
65. Name Object value 96 log debug finding EstadosFacturas instance with property propertyName value value try 4 String queryString from EstadosFacturas as model where model propertyName Query queryObject getSession createQuery queryString queryObject setParameter 0 value return queryObject list catch RuntimeException re log error find by property name failed re throw re public List findByDescripcion Object descripcion return findByProperty DESCRIPCION descripcion public List findByValor Object valor return findByProperty VALOR valor public List findByObservacion Object observacion return findByProperty OBSERVACION observacion public List findByEstado Object estado return findByProperty ESTADO estado public List findByUsuariolngreso Object usuarioIngreso return findByProperty USUARIO_INGRESO usuariolngreso public List findAll log debug finding all EstadosFacturas instances try String queryString from EstadosFacturas Query queryObject getSession createQuery queryString return queryObject list catch RuntimeException re 97 log error find all failed re throw re public EstadosFacturas merge EstadosFactur
66. RUC ruc public List findByDireccionLogo Object direccionLogo return findByProperty DIRECCION LOGO direccionLogo public List findByEstado Object estado return findByProperty ESTADO estado public List findByObservacion Object observacion return findByProperty OBSERVACION observacion public List findByUsuarioIngreso Object usuarioIngreso return findByProperty USUARIO INGRESO usuariolngreso public List findAll log debug finding all Empresas instances try String queryString from Empresas Query queryObject getSession createQuery queryString return queryObject list catch RuntimeException re log error find all failed re throw re public Empresas merge Empresas detachedInstance log debug merging Empresas instance try Empresas result Empresas getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re 91 public void attachDirty Empresas instance log debug attaching dirty Empresas instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re throw
67. Request request HttpServletResponse response IngresoUsuarioForm ingresoUsuarioForm IngresoUsuarioForm form TODO Auto generated method stub String principalError Error Crear Rol try request getSession setAttribute TITULOERROR 38 null request getSession setAttribute ERRORGENERAL null if ingresoUsuarioForm getIdPersona trim equals throw new Exception Debe ingresar a la persona que se le asignar el usuario if ingresoUsuarioForm getDescripcionUsuario trim equals LU throw new Exception Ingrese el nombre del usuario if ingresoUsuarioForm getRol trim equals 1 throw new Exception Seleccione el rol del usuario if ingresoUsuarioForm getObservacion trim equals throw new Exception Seleccione el rol del usuario DAOUtil beginTransaction crearUsuario ingresoUsuarioForm Usuarios request getSession getAttribute Sesion USUARIO getDescUsuario DAOUtil commit request getSession setAttribute PAGINA paginas transacciones seguridad ingresoUsuario Jsp request getSession setAttribute MENSAJEOK n Creacion De Usuario Exitoso la clave inicial del usuario es del 1 al 8 no olvidarse realizar el cambio de clave return mapping findForward procesoExitoso
68. Set opcioneses this opcioneses opcioneses public Set getOpcionesRoleses return this opcionesRoleses public void setOpcionesRoleses Set opcionesRoleses this opcionesRoleses opcionesRoleses 114 4 gt facturacionlsp2 4 58 src EB com general bo E com general escuchadores 48 com general filtros generales 4 FH com general modelo persistentes gt IN OpcionesRoles java package com general modelo persistentes import java util Date Xxx OpcionesRoles entity author MyEclipse Persistence Tools KH public class OpcionesRoles implements java io Serializable Fields private Integer idOpcionRol private Roles roles private Opciones opciones private Date fechaRegistro private String estado private String observacion private Date fechaActualizacion private String usuarioIngreso Constructors default constructor public OpcionesRoles minimal constructor public OpcionesRoles Roles roles Opciones opciones String estado this roles roles this opciones opciones this estado estado full constructor public OpcionesRoles Roles roles Opciones opciones Date fechaRegistro String estado String observacion Date fechaActualizacion String usuariolngreso this roles roles 115 this opciones opciones this fechaRegistro fechaRegistro this esta
69. Tipo this estado estado this fechaRegistro fechaRegistro full constructor 129 String 130 public TiposFmpleados String descripcionTipo String estado Date fechaRegistro String observacion Date fechaActualizacion String usuarioIngreso Set empleadoses his descripcionTipo descripcionTipo his estado estado his fechaRegistro fechaRegistro is observacion observacion his fechaActualizacion fechaActualizacion his usuariolngreso usuariolngreso his empleadoses empleadoses GRUA EEE b Property accessors public Integer getIdTipoEmpleado return this idTipoEmpleado public void setIdTipoEmpleado Integer idTipoEmpleado this idTipoEmpleado idTipoEmpleado public String getDescripcionTipo return this descripcionTipo public void setDescripcionTipo String descripcionTipo this descripcionTipo descripcionTipo public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro 131 public String getObservacion return this observacion public void setObservacion String observacion this observac
70. Xxx x A data access object DAO providing persistence and search support for Contratos entities Transaction control of the save update and delete operations can directly support Spring container managed transactions or they can be augmented to handle user managed Spring transactions Each of these methods provides additional information for how to configure it for the desired type of transaction control see com general modelo persistentes Contratos author MyEclipse Persistence Tools E public class ContratosDAO extends BaseHibernateDAO private static final Log log LogFactory getLog ContratosDAO class property constants public static final String CUENTA cuenta public static final String ESTADO estado 63 public static final String PLAZO plazo public static final String OBSERVACION observacion public static final String _USUARIO_INGRESO usuariolngreso public static final String VALOR_REFERENCIA1L valorReferencial public void save Contratos transientInstance log debug saving Contratos instance try getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete Contratos persistentInstance log debug deleting Con
71. a DAOUtil beginTransaction RolesDAO rolDao new RolesDAO List rolesSistemas rolDao findAll DAOUtil flush DAOUtil commit return rolesSistemas 142 4 facturacionlsp2 4 8 src gt MH com general bo E3 com general escuchadores gt MH com general filtros generales gt M com general modelo persistentes B com general struts 4 FH com general struts action p D ACambiarClave java gt 4 ActivarlmpuestoAction java gt L ActivarRolAction java gt 4 ActivarUsuarioAction java J ActualizarParametrosAction java Generated by MyEclipse Struts Template path templates java JavaClass vtl ay package com general struts action import java util Date import javax servlet http HttpServletRequest import Javax servlet http HttpServletResponse import org apache struts action Action import org apache struts action ActionForm import org apache struts action ActionForward import org apache struts action ActionMapping import com general modelo persistentes Parametros import com general modelo persistentes ParametrosDAO import com general modelo persistentes Usuarios import com general struts form ActualizarParametrosForm import com general util DAOUtil import com general util Sesion Xxx x MyEclipse Struts x Creation date 08 02 2007 XDoclet definition struts action path actualizarParametros
72. aciones ciclosFacturaciones his clientes clientes his cuenta cuenta his fechalnicio fechalnicio his fechaRegistro fechaRegistro his estado estado GE Gh GE CUA es ct full constructor public Contratos Empleados empleados CiclosFacturaciones ciclosFacturaciones Clientes clientes String cuenta Date fechalnicio Date fechaRegistro String estado Date fechaFin Date fechaActualizacion String plazo String observacion String usuariolngreso String valorReferencial Set facturases Set serviciosContratadoses this empleados empleados this ciclosFacturaciones ciclosFacturaciones this clientes clientes this cuenta cuenta this fechalnicio fechalnicio 59 his fechaRegistro fechaRegistro his estado estado his fechaFin fechaFin his fechaActualizacion fechaActualizacion is plazo plazo his observacion observacion his usuariolngreso usuariolngreso his valorReferencial valorReferencial his facturases facturases this serviciosContratadoses serviciosContratadoses Gta Ge Gh Gh gta Gh igh Gt a J Property accessors public Integer getIdContrato return this idContrato public void setIdContrato Integer idContrato this idContrato idContrato public Empleados getEmpleados return this empleados public void setFmplead
73. an this valorMaxPlan valorMaxPlan this estado estado this fechaRegistro fechaRegistro this fechaActualiza fechaActualiza this requerimiento requerimiento this respuesta respuesta this usuarioIngreso usuarioIngreso this usuarioDespacha usuarioDespacha this accion accion Property accessors public Integer getIdAprovisiona return this idAprovisiona String String public void setIdAprovisiona Integer idAprovisiona this idAprovisiona public String getCodiPlan return this codiPlan idAprovisiona 121 public void setCodiPlan String codiPlan this codiPlan codiPlan public String getValorMaxPlan return this valorMaxPlan public void setValorMaxPlan String valorMaxPlan this valorMaxPlan valorMaxPlan public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaActualiza return this fechaActualiza public void setFechaActualiza Date fechaActualiza this fechaActualiza fechaActualiza public String getRequerimiento return this requerimiento public void setRequerimiento String requerimiento this requerimiento requerimiento public String g
74. as detachedInstance log debug merging EstadosFacturas instance try EstadosFacturas result EstadosFacturas getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re public void attachDirty EstadosFacturas instance log debug attaching dirty EstadosFacturas instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re throw re public void attachClean EstadosFacturas instance log debug attaching clean EstadosFacturas instance try A GI getSession lock instance LockMode NONE log debug attach successful catch RuntimeException re log error attach failed re throw re 98 4 El facturacionlsp2 4 8 src gt MH com general bo gt 8 com general escuchadores gt M com general filtros generales 4 H com general modelo persistentes 45 Facturas java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx x Facturas entity author MyEclipse Persistence Tools aj public class Facturas implements java io Serializable Fields private Integer idFactura private Empleados empleados private Contratos con
75. ases public Set getContratoses return this contratoses public void setContratoses Set contratoses this contratoses contratoses 4 H com general modelo persistentes J BaseHibernateDAO java 45 CiclosFacturaciones java D CiclosFacturacionesDAO java 45 Clientes java 3 ClientesDAO java package com general modelo persistentes import java util List 53 import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode import org hibernate Query import org hibernate criterion Example Xxx x A data access object DAO providing persistence and search support for Clientes entities Transaction control of the save update and delete operations can directly support Spring container managed transactions or they E can be augmented to transactions Each of these methods provides additional configure it for the desired type of transaction handle user managed Spring information for how to control see com general modelo persistentes Clientes author MyEclipse Persistence Tools x7 BaseHibernateDAO Log log public class ClientesDAO extends private static final LogFactory getLog ClientesDAO class property constants public static final direccionEntregaFact public static final String ESTADO public static final String T telefonoTrabajo
76. ault constructor public CiclosFacturaciones minimal constructor public CiclosFacturaciones String descripcionCiclo String estado Date fechaRegistro this descripcionCiclo descripcionCiclo this estado estado this fechaRegistro fechaRegistro full constructor public CiclosFacturaciones String descripcionCiclo String estado Date fechaRegistro String observacion Date fechaActualizacion String usuariolngreso Set contratoses this descripcionCiclo descripcionCiclo this estado estado this fechaRegistro fechaRegistro this observacion observacion 43 descripcionCiclo this fechaActualizacion fechaActualizacion this usuariolngreso usuariolngreso this contratoses contratoses Property accessors public Integer getIdCiclo return this idCiclo public void setIdCiclo Integer idCiclo this idCiclo idCiclo public String getDescripcionCiclo return this descripcionCiclo public void setDescripcionCiclo String this descripcionCiclo descripcionCiclo public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getObservacion
77. c Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechalnicio return this fechalnicio public void setFechalnicio Date fechaInicio this fechaInicio fechalnicio public Date getFechaFin return this fechaFin public void setFechaFin Date fechaFin this fechaFin fechaFin public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getNumeroAutorizacion 125 return this numeroAutorizacion public void setNumeroAutorizacion String numeroAutorizacion this numeroAutorizacion numeroAutorizacion public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getUsuarioIngreso return this usuariolngreso public void setUsuariolngreso String usuariolngreso this usuariolngreso usuariolngreso 4 facturacionlsp2 4 GP src gt MH com general bo gt HH com general escuchadores gt 8 com general filtros generales 4 8 com general modelo persistentes 15 Sucursales java package com general modelo persistentes import java util Date import java util HashSet import java uti
78. ccessful RuntimeException re ete failed re nteger id h id Empre sas 89 com general modelo persistentes Empresas id return instance catch RuntimeException re log error get failed re throw re public List findByExample Empresas instance log debug finding Empresas instance by example try List results getSession createCriteria com general modelo persistentes Empresas add Example create instance list log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String propertyName Object value log debug finding Empresas instance with property propertyName value value try String queryString from Empresas as model where model propertyName Query queryObject getSession createQuery queryString queryObject setParameter 0 value return queryObject list catch RuntimeException re log error find by property name failed re throw re public List findByRazonSocial Object razonSocial return findByProperty RAZON_SOCIAL razonSocial 90 public List findByRuc Object ruc return findByProperty
79. chAlgorithmException Invalid KeyException IllegalBloc kSizeException Unsuppo PBI T SecretKeyFactory get Nos rtedEncodingException Cipher Cipher dcipher Crear la key KeySpec SecretKey et keySpec String ecipher Cipher getl cipher uchPaddingException InvalidAlgorithmParameterException BadPaddingException null null keySpec new ES ITERATION COUN EKeySpec passPhrase toCharArray SALT_BYT Instance P key dcipher Cipher get Preparar los paran AlgorithmParameterSpec paramSpec BEParameterSpec SALT_BYTES IT ERAT ON_COUNT Crear los ciphers ecipher init Cipher ENCRYPT_MODI key h Liy mi dcipher init Cipher Encodear la cadena byte utf8 Encriptar enc public str NoSuchAlgorithmException InvalidKeyException O Exception IllegalBlocksi DECRYPT MOD key a bytes BAS cipher doFinal utf8 Encodear bytes a baseb4 urn new sun misc E64 Encoder BEWithMD5AndDES generateSecr Instance key getAlgorithm Instance key getAlgorithm netros para los ciphers new paramSpec paramSpec usando utf 8 str getBytes UTF8 para obten
80. d throw new Exception EI usuario ps_user toUpperCase tiene una clave diferente registrada en el sistema l_usuario setReintentosClave short 0 return 1 usuario 4 E facturacionIsp2 4 src 8 com general bo 4 HH com general escuchadores J InicializadorContexto java J ManejadorHibernateRequest jawa 14 package com general escuchadores Inicializa los log de la aplicacion de auditoria registra en la consola de la aplicacion cuando inicia y cuando termina la aplicacion 7 15 import javax servlet ServletContextEvent import javax servlet ServletContextListener import org apache log4j Level import org apache log43 Logger import org apache log4j PropertyConfigurator public class InicializadorContexto implements ServletContextListener static Logger logger Logger getLogger InicializadorContexto class public void contextDestroyed ServletContextEvent p_sc System out println Destrucion de la aplicacion web if logger isEnabledFor Level INFO logger info Destruyendo la aplicacion p_sc getServletContext getServletContextName public void contextInitialized ServletContextEvent p_sc PropertyConfigurator configure p_sc getServletContext getRealPath WEB INF log43 properties try
81. debug delete successful catch RuntimeException re log error delete failed re throw re public CiclosFacturaciones findById java lang Integer id log debug getting CiclosFacturaciones instance with a a id try CiclosFacturaciones instance CiclosFacturaciones getSession get com general modelo persistentes CiclosFacturac iones id return instance catch RuntimeException re log error get failed re throw re public List findByExample CiclosFacturaciones instance log debug finding CiclosFacturaciones instance by example try List results getSession createCriteria com general modelo persistentes CiclosFacturaciones add Example create instance list log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re 47 public List findByProperty String propertyName Object value log debug finding CiclosFacturaciones instance with property propertyName value value try String queryString from CiclosFacturaciones as model where model propertyName Query queryObject getSession createQuery queryString queryObject setParameter 0 value return queryObject list catch RuntimeException re log error find
82. do estado this observacion observacion this fechaActualizacion fechaActualizacion this usuariolngreso usuariolngreso Property accessors public Integer getIdOpcionRol return this idOpcionRol public void setIdOpcionRol Integer idOpcionRol this idOpcionRol idOpcionRol public Roles getRoles return this roles public void setRoles Roles roles this roles roles public Opciones getOpciones return this opciones public void setOpciones Opciones opciones this opciones opciones public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getEstado return this estado public void setEstado String estado this estado estado public String getObservacion return this observacion 116 public void setObservacion String observacion this observacion observacion public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuariolngreso public void setUsuariolngreso String usuariolngreso this usuariolngreso usuariolngreso 4 E facturacionlsp2 4 8 src gt MH com general bo FH com general escuchadores g
83. document all fadeimgleft style posLeft scrollerleft document all fadeimgright style posTop scrollertop document all fadeimgright style posLeft scrollerleft scrollerwidth fadeimgwidth Lipleft 0 Lipright 0 Liptop 0 Lipbottom scrollerheight document all text style clip rect cliptop clipright clipbottom clipleft scrolltext cl El cl cl if document layers document text document write textcontent document text document close document fadeimgleft document write fadeimgleftcontent document fadeimgleft document close document fadeimgright document write fadeimgrightcontent document fadeimgright document close textwidth document text document width document text top scrollertop document text left scrollerleft scrollerwidth document fadeimgleft top scrollertop document fadeimgleft left scrollerleft document fadeimgright top scrollertop document fadeimgright left scrollerleft scrollerwidth fadeimgwidth document text clip left 0 document text clip right 0 document text clip top 0 document text clip bottom scrollerheight scrolltext function scrolltext if document all 185 if document all text style posLeft5 scrollerleft textwidth document all text style posLeft step clipright step if clipright gt scrollerwidth clipleft ste
84. dula property private String cedula ruc property private String ruc 154 observacion property private String observacion primerNombre property private String primerNombre apellidoMaterno property private String apellidoMaterno email property private String email pasaporte property private Strin direccion g pasaporte property private Strin g direccion telefono property private String telefono private String sexo g private String idPersona private String telefonoTrabajo private String correspondencia Generated Methods el g public String getCorrespondencia return correspondencia public void setCorrespondencia String correspondencia this correspondencia correspondencia public String getTelefonoTrabajo return telefonoTrabajo public void setTelefonoTrabajo String telefonoTrabajo this telefonoTrabajo telefonoTrabajo 155 public String getIdPersona return idPersona public void setIdPersona String idPersona this idPersona idPersona public String getSexo return sexo public void setSexo String sexo this sexo sexo Xxx x Method validate x param mapping param request return ActionErrors public ActionErrors validate ActionMapping map
85. dulos padres del rol Vector modulosPadresAsignados new Vector Set modulosRol rol getOpcionesRoleses Iterator modulosAsigandos modulosRol iterator Modulos Asignados while modulosAsigandos hasNext OpcionesRoles opcionesRol OpcionesRoles modulosAsigandos next if opcionesRol getEstado equals A Opciones opcion opcionesRol getOpciones if opcion getOpciones null if opcion getEstado equals A modulosPadresAsignados add opcion Modulos no asigandos OpcionesDAO opcionesDAo new OpcionesDAO Vector modulosNoAsigandos new Vector List opciones opcionesDAo findByProperty opcionesDAo ESTADO A Iterator modulosNAsig opciones iterator int bandera 0 150 while modulosNAsig hasNext Opciones opcionl Opciones modulosNAsig next bandera 0 if opcionl getOpciones nul1 for int 0 modulosPadresAsignados size gt i itt Opciones opcion2 Opciones modulosPadresAsignados elementAt 1 if opcion2 getIdOpcion toString equals opcionl getIdOpcion tos tring bandera 1 encontro unal ocurrencia break modu if bandera 0 insertarlo modulosNoAsigandos add opcionl request getSession setAttribute ROL_ENC rol request getSession setAttribute OPC_ASIG losPadresAsignados
86. e content text html charset 150 8859 1 gt lt title gt BEMUS SOFT SEGURIDAD Cambio de Clave lt title gt lt Exception error Exception request getSession getAttribute ERRORGENERAL Usuarios 1_usuario Usuarios session getAttribute Sesion USUARIO String lsInicio request getParameter inicial lsInicio lsInicio null lsInicio String lsClaveActual 1 usuario getClave ST link rel stylesheet href lt request getContextPath gt css estiloFormas css type text css gt lt link gt lt script type text javascript src lt request getContextPath gt js general js gt lt script gt lt script type text javascript language Javascript1 1 src lt request getContextPath gt js validacionesStruts js gt lt script gt lt html javascript formName formaCambioClave staticJavascript false gt lt script type text javascript gt 179 function validarClaveActual object var claveIngresada object value var claveActual lt UtilCryptography desencriptar lsClaveActual gt if clavelngresada claveActual alert La clave que ingreso no es igual a su clave q g actual object value return function validarClaveNueva object var claveConfNuevaIngresada object value var claveNuevaIngresada formaCambioClave claveNueva value if
87. echaFactura fechaFactura his subTotal subTotal his totalIva totallva his totallce totalIce his totalltem totalltem his totalDescuento totalDescuento his estado estado his fechaActualizacion fechaActualizacion his observacion observacion his usuariolngreso usuariolngreso his detallesPagoses detallesPagoses his detallesFacturases detallesFacturases CESE chet ie EEU EP A GP Property accessors public Integer getIdFactura return this idFactura 100 public void setIdFactura Integer idFactura this idFactura idFactura public Empleados getEmpleados return this empleados public void setFmpleados Empleados empleados this empleados empleados public Contratos getContratos return this contratos public void setContratos Contratos contratos this contratos contratos public Clientes getClientes return this clientes public void setClientes Clientes clientes this clientes clientes public String getNumeroFactura return this numeroFactura public void setNumeroFactura String numeroFactura this numeroFactura numeroFactura public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRe
88. er cadena ncode throws nc static String desencriptar String passPhrase InvalidKeySpec Exception NoSuchPaddingException e Cipher Cipher dcipher Crear la key cipher null BadPadding null InvalidAlgorithmParameterException Exception Exception 162 KeySpec keySpec new PBEKeySpec passPhrase toCharArray SALT_BYTES ERATION_COUNT SecretKey key SecretKeyFactory getInstance PBEWithMD5AndDES generateSecr et keySpec ecipher Cipher getInstance key getAlgorithm dcipher Cipher getInstance key getAlgorithm Preparar los parametros para los ciphers AlgorithmParameterSpec paramSpec new PBEParameterSpec SALT_BYTES ITERATION_COUNT Crear los ciphers ecipher init Cipher ENCRYPT_MODE key paramSpec dcipher init Cipher DECRYPT_MODE key paramSpec Decodear base64 y obtener bytes byte dec new sun misc BASE64Decoder decodeBuffer str Desencriptar byte utf8 dcipher doFinal dec Decodear usando utf 8 return new String utf8 UTF8 HI public static String desencriptar String str throws InvalidKeyException InvalidKeySpecException NoSuchAlgorithmException NoSuchPaddingException InvalidAlgorithmParameterExcep
89. ervacion this observacion observacion public Date getFechaActualizacion 134 return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuarioIngreso this usuariolngreso usuariolngreso public Set getParametroses return this parametroses public void setParametroses Set parametroses this parametroses parametroses 4 He facturacionlsp2 4 58 src gt MH com general bo gt HH com general escuchadores gt 8 com general filtros generales 4 3 com general modelo persistentes b D Usuarios java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx x Usuarios entity author MyEclipse Persistence Tools EL public class Usuarios implements java io Serializable 135 Fields private Integer idUsuario private Roles roles private Personas personas private String descUsuario private String clave private String estado private Date fechaRegistro private String observacion private String usuariolngreso private Date fechaActualizacion private Set loginUsuarioses new HashSet 0 private String cambioClave C
90. es Usuarios import com general util DAOUtil import com general util Sesion Xxx x MyEclipse Struts x Creation date 08 02 2007 XDoclet definition struts action validate true kj public class CreacionContrato extends Action Generated Methods 7 Xxx x Method execute x param mapping param form param request param response return ActionForward al public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response TODO Auto generated method stub try Personas persona Personas request get Session getAttribute PERSONAENCONTRA DA Clientes cliente 32 T Clientes request getSession getAttribute CLIENT DO Vector planes ENCONTRA Vector request getSession getAttribute CARRITOCOMPRAS CiclosFacturacionesDAO ciclo String idCiclo request getParameter ciclo String observacion request getParameter observacion Eso necesito if persona null throw new Exception No se encuentra la persona en la session por favor revisar if cliente null throw new Exception No se encuentra el cliente en la session por favor revisar if planes null throw new Exception No se encuentra los planes seleccionados por favor revisar if planes size 0
91. etEstado String estado this estado estado public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public Date getFechaRegistro return this fechaRegistro 70 public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion 4 gt facturacionlsp2 4 8 src 89 com general bo 8 com general escuchadores 8 com general filtros generales 4 8 com general modelo persistentes 15 DetallesFacturasDAO java package com general modelo persistentes import java util Date import java util List import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode import org hibernate Query import org hibernate criterion Example Xxx x A data access object DAO providing persistence and search support for x DetallesFacturas entities Transaction control of the save update and x delete operations can directly support Spring container
92. etRespuesta return this respuesta public void setRespuesta String respuesta this respuesta respuesta public String getUsuarioIngreso 122 return this usuarioIngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public String getUsuarioDespacha return this usuarioDespacha public void setUsuarioDespacha String usuarioDespacha this usuarioDespacha usuarioDespacha public String getAccion return this accion public void setAccion String accion this accion accion 4 tr facturacionlsp2 4 8 src EB com general bo E3 com general escuchadores gt 8 com general filtros generales 4 H com general modelo persistentes b 5 SecuenciasFacturas java package com general modelo persistentes import java util Date Xxx x SecuenciasFacturas entity author MyEclipse Persistence Tools El public class SecuenciasFacturas implements java io Serializable Fields private Integer idSecuencia private String numeroInicial private String numeroFinal private String estado private Date fechaRegistro 123 private Date fechalnicio private Date fechaFin private Date fechaActualizacion private String numeroAutorizacion private String observacion private String usuariolngreso private Integer siguienteNumero Constructors public Integer getSiguienteNumero
93. ethod execute param mapping param form param request param response return ActionForward A AR E F FX N public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest HttpServletResponse response TODO Auto generated method stub try path sdsdsd path sdsdsd request 141 PERSONAENCONTRADA String idRol request getParameter idRol DAOUtil beginTransaction activarRol idRol DAOUtil commit List rolesFinal getRolesSistema request getSession setAttribute ROLESSISTEMAS rolesFinal request getSession setAttribute MENSAJEOK Inactivacion Exitosa return mapping findForward procesoExitoso catch Exception e DAOUtil rollback e printStackTrace request getSession setAttribute TITULOERROR Inactivacion De Rol request getSession setAttribute ERRORGENERAL e new Exception principalError e getMessage return mapping findForward procesoFallido private void activarRol String idRol TODO Auto generated method stub RolesDAO rolDao new RolesDAO Roles rol rolDao findById new Integer idRol rol setEstado A rol setFechaActualizacion new Date rolDao attachDirty rol public List getRolesSistem
94. getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re throw re public void attachClean CiclosFacturaciones instance log debug attaching clean CiclosFacturaciones instance try getSession lock instance LockMode NON log debug attach successful catch RuntimeException re log error attach failed re throw re GI li 4 8 com general modelo persistentes b D BaseHibernateDAO java gt J CiclosFacturaciones java gt MM CiclosFacturacionesDAO java gt IN Clientes java 49 package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx x Clientes entity author MyEclipse Persistence Tools 4 public class Clientes implements java io Serializable Fields private Integer idCliente private Personas personas private String direccionEntregaFact private Date fechalnicio private Date fechaRegistro private Date fechaFin private String estado private String telefonoTrabajo private String observacion private Date fechaActualizacion private String usuariolngreso private Set facturases new HashSet 0 private Set contratoses new HashSet 0 Constructors default constructor public Clientes minimal constructor public Clientes
95. gistro public Date getFechaFactura return this fechaFactura 101 public void setFechaFactura Date fechaFactura this fechaFactura fechaFactura public Double getSubTotal return this subTotal public void setSubTotal Double subTotal this subTotal subTotal public Double getTotallva return this totallva public void setTotallva Double totallva this totallva totallva public Double getTotallce return this totallce public void setTotallce Double totallce this totalIce totallce public Integer getTotalltem return this totalltem public void setTotalltem Integer totalltem this totalltem totalltem public Double getTotalDescuento return this totalDescuento public void setTotalDescuento Double totalDescuento this totalDescuento totalDescuento public String getEstado return this estado 102 public void setEstado String estado this estado estado public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getObservacion return this observacion public void setObservacion String observacion this observacion observac
96. gos instance by example try A List results getSession createCriteria com general modelo persistentes DetallesPagos add Example create instance list F log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String propertyName Object value log debug finding DetallesPagos instance with property propertyName value value try String queryString from DetallesPagos as model where model propertyName 2 Query queryObject getSession createQuery queryString queryObject setParameter 0 value 81 return queryObject list catch RuntimeException re log error find by property name failed re throw re public List findByValor Object valor return findByProperty VALOR valor public List findByDescripcion Object descripcion return findByProperty DESCRIPCION descripcion public List findByReferenciaBancaria Object referenciaBancaria return findByProperty REFERENCIA_BANCARIA referenciaBancaria public List findByNumeroTransaccion Object numeroTransaccion return findByPropert y NUMERO_TRANSACCION numeroTransaccion
97. gt lt tr gt lt tr gt lt td height 125 gt nbsp lt td gt lt td valign top width 15 gt lt fieldset gt lt table class tablaLoggin width 70 border 0 cellpadding 0 cellspacing 0 gt c DWLayoutTable 5 172 lt tr gt lt td width 16 gt lt td gt lt td height 18 colspan 3 gt lt FONT face Verdana Arial Helvetica sans serif size 2 gt lt logic messagesPresent gt lt html messages id error gt lt S errors gt lt html messages gt lt logic messagesPresent gt lt FONT gt lt td gt lt td width 18 gt lt td gt lt tr gt lt tr gt lt td gt lt td gt lt td width 85 height 22 valign middle gt lt span class Estilo3 gt lt bean message key etiquetas login user gt lt span gt lt td gt lt td colspan 2 valign top gt lt html text property usuario onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off styleClass cajaTexto size 19 gt lt td gt lt td gt lt td gt lt tr gt lt tr gt lt td gt lt td gt lt td height 22 valign middle gt lt span class Estilo3 gt lt bean message key etiquetas login clave gt lt span gt lt td gt lt td colspan 2 valign top gt lt html password property clave onfocus cambiarEstiloCajaTextoPass event on onblur cambiarEstiloCajaTextoPass event off styleClass cajaTextoPa
98. h gt do sq3 sth3 dbh gt prepare sq3 sth3 gt execute sq3 qq UPDATE servicios contratados SET estado l WHERE estado A AND id contrato contrato AND descripcion_servicio CORREO Y dbh gt do sq3 sth3 dbh gt prepare sq3 sth3 gt execute 196 Script Corte usr bin perl use DBI db DBI mysql facturacionisp 127 0 0 1 username root Spass redes now localtime time values split 5now print values 1 values 2 values 4 H mesmag values 1 dbh DBI gt connect db username pass sql qq SELECT FROM inactivacion_servicios WHERE estado T dbh gt do sql sth dbh gt prepare sql sth gt execute Sfecha1 Svalues 4 5mes 01 print Sfecha1 while array sth gt fetchrow_array Sidac array 0 ip Sarray 2 iptables t nat D POSTROUTING o eth0 s ip 32 j MASQUERADE sq13 qq DELETE FROM nat WHERE ip ip dbh gt do sq13 sth13 dbh gt prepare sq13 sth13 gt execute sq2 qq UPDATE inactivacion_servicios SET estado E WHERE estado l AND id_inactivacion Sidac AND ip_maquina ip dbh gt do sq2 sth1 dbh gt prepare sq2 sth1 gt execute sq16 qq UPDATE servicios contratados SET estado l valor_referencia_3 Automatico inactivado WHERE estado A AND valor_referencia_2 Sip A
99. iar equals 164 texto auxiliar ip auxiliar substring 6 21 SABI DatosIp System out printin ip mac s substring 20 37 DatosIp dat new vec add dat dat setIp ip dat setMac mac System out println mac mac texto s An flag 0 System out println texto return vec public static void main String args try 4 leerDhcp catch Exception e TODO Auto generated catch block e printStackTrace package com general util public class ValidacionesVarias Valida la cedula o el ruc public static boolean validarDocumento String numero throws Exception boolean valor true try int suma 0 int residuo 0 165 boolean privada false boolean publica false boolean natural false int numeroProvincias 22 int digitoVerificador 0 int modulo 11 int dl d2 d3 d4 d5 do d7 d8 d9 A107 int p1 p2 p3 p4 ps po p7 p8 p9 di d2 d3 d4 d5 d6 d7 d8 d9 d10 0 Pl p2 p3 p4 p5 po p7 p8 p9 0 if numero length lt 10 valor false throw new Exception La identificacion no tien 1 numero de caractares validos Los primeros dos digitos corresponden al codigo de la provincia int provincia Integer parselnt numero substring 0 2 if provincia lt 0 provincia gt numeroProvinc
100. ias valor false throw new Exception El codigo de la provincia es invalido Aqui almacenamos los digitos de la cedula en variables dl Integer parseInt numero substring 0 1 d2 Integer parseInt numero substring 1 2 d3 Integer parseInt numero substring 2 3 7 d4 Integer parseInt numero substring 3 4 d5 Integer parseInt numero substring 4 5 d6 Integer parseInt numero substring 5 6 d7 Integer parseInt numero substring 6 7 d8 Integer parseInt numero substring 7 8 7 d9 Integer parseInt numero substring 8 166 di0 Integer parseInt numero substring 9 10 El tercer digito es 9 para sociedades privadas y extranjeros 6 para sociedades publicas menor que 6 0 1 2 3 4 5 para personas naturales if d3 d3 8 valor false throw new Exception El tercer digito ingresado es invalido Solo para personas naturales modulo 10 if d3 lt 6 natural true modulo 10 pl dl 2 if pl gt 10 pl 9 p2 d2 1 if p2 gt 10 p2 9 p3 d3 2 if p3 gt 10 p3 9 pa d4 1 if p4 gt 10 p4 9 po edb F 27 if p5 gt 10 ps 9g p6 d6 1 if p6 gt 10 p6 9 p7 d7 2 if p7 gt 10 p7 3 p8 d8 1 if p8 gt 10 p8 9 p9 do 2 if p9 gt 10 pI 97 Solo para sociedades p
101. id setCaontidadMaxima Integer caontidadMaxima this caontidadMaxima caontidadMaxima default constructor public TiposProdcutos 104 minimal constructor public TiposProdcutos String descripcionTipo String estado this descripcionTipo descripcionTipo this estado estado full constructor public TiposProdcutos String descripcionTipo String estado String observacion Date fechaRegistro Date fechaActualizacion String usuarioIngreso Set productoses his descripcionTipo descripcionTipo his estado estado his observacion observacion is fechaRegistro fechaRegistro his fechaActualizacion fechaActualizacion his usuariolngreso usuariolngreso his productoses productoses ot ct ct ct ct ct ct b Property accessors public Integer getIdTipoProducto return this idTipoProducto public void setIdTipoProducto Integer idTipoProducto this idTipoProducto idTipoProducto public String getDescripcionTipo return this descripcionTipo public void setDescripcionTipo String descripcionTipo this descripcionTipo descripcionTipo public String getEstado return this estado public void setEstado String estado this estado estado 105 public String getObservacion return this observacion public void setObservacion String observacion
102. ig import javax servlet ServletException import javax servlet ServletRequest import javax servlet ServletResponse import javax servlet http HttpServletRequest import jJavax servlet http HttpServletResponse import javax servlet http HttpSession 17 import org apache commons logging Log import org apache commons logging LogFactory import com general modelo persistentes Usuarios import com general util Sesion public class FilSensarUser implements Filter private FilterConfig filterConfig null public void init FilterConfig filterConfig throws ServletException this filterConfig filterConfig public void doFilter ServletRequest request ServletResponse response FilterChain chain throws ServletException try Log log LogFactory getLog FilSensarUser class log debug EJECUCION DE FILTRO GENERAL System out println Inicio Ejecucion De Filtro General this getClass new Date HttpServletRequest re HttpServletRequest request HttpServletResponse rere HttpServletResponse response HttpSession sesionWeb re getSession String nombreUri re getRequestURI String nombreContext re getContextPath String nombrePaginaActual String rutalnicial http re getRemoteAddr re getServerPort re getCo ntextPath nombreUri
103. inado el contrato tendria que pagar el costo prorrateado por los dias que gozo de el servicio El en caso de que algun usuario dejase de laborar para el ISP mediante nuestra aplicaci n solo podr inactivarlo mas no borrarlo Un usuario solo podra tener un rol El administrador podra agregar mas opciones a los roles si asi lo deseara El dia de corte de la factura se enviara un mail al cliente final informandole el valor que debe cancelar solo dentro de su dominio El corte se realizara cinco dias despu s de la fecha de corte procurando darle dias de gracia usandolo como una estrategia para fidelizar clientes CAPITULO 3 3 Herramientas y configuraciones A continuaci n mencionaremos las herramientas de software necesarias para el desarrollo de la aplicaci n e IDE MyEclipse 5 e Java 5 e Tomcat 5 e MySQL 5 e Linux e Centos 5 e DHCP e CBQ e SendMail e Iptables 3 1 MyEclipse MyEclipse es un IDE creado y mantenido por la compa a Genuitec un miembro fundador del eclipse 10 MyEclipse se construye sobre plataforma Eclipse e integra el propietario y soluciones abiertas de la fuente en el ambiente del desarrollo 3 2 Tomcat Tomcat es un servidor web con soporte de servlets y JSPs Tomcat no es un servidor de aplicaciones como JBoss o JOnAS Incluye el compilador Jasper que compila JSPs convirti ndolas en servlets El motor de servlets de Tomcat a menudo se presenta en combinaci n con e
104. ind by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String propertyName Object value log debug finding Clientes instance with property propertyName value value try 55 String queryString from Clientes as model where model propertyName Query queryObject getSession createQuery queryString queryObject setParameter 0 value return queryObject list catch RuntimeException re log error find by property name failed re throw re public List findByDireccionEntregaFact Object direccionEntregaFact return findByProperty DIRECCION_ENTREGA_FACT direccionEntregaFact public List findByEstado Object estado return findByProperty ESTADO estado public List findByTelefonoTrabajo Object telefonoTrabajo return findByProperty TELEFONO_TRABAJO telefonoTrabajo public List findByObservacion Object observacion return findByProperty OBSERVACION observacion public List findByUsuarioIngreso Object usuarioIngreso return findByProperty USUARIO_INGRESO usuariolngreso ublic List findAll log deb
105. int n sq2 qa SELECT FROM facturas WHERE estado AND DATE_FORMAT fecha_factura y mM d DATE_FORMAT NOW Sy Yom d y dbh gt do sq2 sth1 dbh gt prepare sq2 sth1 gt execute while array2 sth1 gt fetchrow_array idcliente array2 5 idcontrato array2 4 print SELECT FROM clientes WHERE id cliente idcliente print n sq3 qq SELECT FROM clientes WHERE id cliente Sidcliente dbh gt do sq3 sth3 dbh gt prepare sq3 sth3 gt execute while array3 sth3 gt fetchrow_array idpersona array3 1 print SELECT FROM personas WHERE id persona Sidpersona print n sq4 qq SELECT FROM personas WHERE id persona Sidpersona dbh gt do sq4 sth4 dbh gt prepare sq4 sth4 gt execute while array4 sth4 gt fetchrow_array nombre Sarray4 4 array4 5 print SELECT FROM servicios contratados WHERE id contrato Sidcontrato AND descripcion_servicio CORREO print n sqi1 qq SELECT FROM servicios contratados WHERE id contrato Sidcontrato AND descripcion servicio CORREO dbh gt do sq11 sth11 dbh gt prepare sq1 1 sth1 1 gt execute while array11 sth11 gt fetchrow_array cuenta array1 1 8 print cuenta print n to cuenta a Sdominio print Sto 199 from rootOmail bemusoft com valor array2 7 Sarray2
106. ion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public Set getDetallesPagoses return this detallesPagoses public void setDetallesPagoses Set detallesPagoses this detallesPagoses detallesPagoses public Set getDetallesFacturases return this detallesFacturases public void setDetallesFacturases Set detallesFacturases this detallesFacturases detallesFacturases 103 4 facturacionlsp2 4 8 src gt MH com general bo E3 com general escuchadores gt MH com general filtros generales 4 8 com general modelo persistentes gt M TiposProdcutos java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx x TiposProdcutos entity author MyEclipse Persistence Tools 7 public class TiposProdcutos implements java io Serializable Fields private Integer idTipoProducto private String descripcionTipo private String estado private String observacion private Date fechaRegistro private Date fechaActualizacion private String usuarioIngreso private Set productoses new HashSet 0 private Integer caontidadMaxima Constructors public Integer getCaontidadMaxima return caontidadMaxima public vo
107. ion observacion public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuarioIngreso public void setUsuariolngreso String usuariolngreso this usuarioIngreso usuariolngreso public Set getEmpleadoses return this empleadoses public void setEmpleadoses Set empleadoses this empleadoses empleadoses y 4 2 facturacionlsp2 4 58 src EB com general bo E3 com general escuchadores gt 8 com general filtros generales 4 8 com general modelo persistentes 15 TiposParametros java package com general modelo persistentes import java util Date import java util HashSet import java util Set 132 Xxx x TiposParametros generated by MyEclipse Persistence Tools ty public class TiposParametros implements java io Serializable Fields private private private privat Integer idTipoParametro String descripcion String estado private private private private Const defa public T Date fechaRegistro String observacion Date fechaActualizacion String usuariolngreso Set parametroses new HashSet 0 ructors ult constrictor iposParametros
108. ion De Rol request getSession setAttribute ERRORGENERAL e new Exception principalError e getMessage return mapping getInputForward facturacionlsp2 4 58 src gt M com general bo 8 com general escuchadores gt MH com general filtros generales gt MH com general modelo persistentes B com general struts 4 SB com general struts action gt F ACambiarClave java p f ActivarlmpuestoAction java b D ActivarRolAction java 140 Generated by MyEclipse Struts Template path templates java JavaClass vtl package com general struts action import java util Date import java util List import javax servlet http HttpServletRequest import javax servlet http HttpServletRespons mport org apache struts action Action mport org apache struts action ActionForm H mport org apache struts action ActionForward mport org apache struts action ActionMapping mport mport H com general modelo persistentes Roles com general modelo persistentes RolesDAO H mport com general util DAOUtil MyEclipse Struts Creation date 10 23 2009 XDoclet definition struts action validate true struts action forward redirect true struts action forward redirect true K7 public class ActivarRolAction extends Action Generated Methods KJ AR AH XA name ok name fallo M
109. ionl getOpciones nul1 for int i 0 modulosPadresAsignados size gt i itt Opciones opcion2 Opciones modulosPadresAsignados elementAt 1 if opcion2 getIdOpcion toString equals opcionl getIdOpcion tos tring bandera 1 encontro una ocurrencia break if bandera 0 insertarlo modulosNoAsigandos add opcionl DAOUtil commit datos request rol request getSession setAttribute ROL_ENC FOLI request getSession setAttribute OPC_ASIG modulosPadresAsignados request getSession setAttribute OPC_NO_ASIG modulosNoAsigandos return mapping findForward ok catch Exception e e printStackTrace DAOUtil rollback request getSession setAttribute TITULOERROR Ahadir Opciones request getSession setAttribute ERRORGENERAL 149 e new Exception principalError e getMessage return mapping findForward fallo public void datos HttpServletRequest request Roles roll throws Exception String idRol roll getIdRol toString DAOUtil beginTransaction RolesDAO rolDao new RolesDAO Roles rol rolDao findById new Integer idRol if rol null throw new Exception No se encontro el rol con codigo idRol obtener los mo
110. istro this fechaRegistro fechaRegistro public Date getFechaPago return this fechaPago public void setFechaPago Date fechaPago this fechaPago fechaPago public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuarioIngreso usuarioIngreso 2 facturacionlsp2 4 58 src D H com general bo E3 com general escuchadores gt M com general filtros generales 4 H com general modelo persistentes 15 DetallesPagosDAO java package com general modelo persistentes 79 import java util Date import java util List import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode import org hibernate Query import org hibernate criterion Example public class DetallesPagosDAO extends BaseHibernateDAO private static final Log log LogFactory getLog DetallesPagosDAO class property constants public static final String VALOR valor public static final String DESCRIP
111. java util public class DetallesPagos implements java io Serializable Fields private private private private private private private private private private private private private Constructors Date Integer idDetallePago FormasPagos formasPagos Facturas facturas Double valor String descripcion String referenciaBancaria String numeroTransaccion String estado Date fechaRegistro Date fechaPago Date fechaActualizacion String observacion String usuariolngreso 76 default constructor public DetallesPagos minimal constructor public DetallesPagos FormasPagos formasPagos Facturas facturas String estado this formasPagos formasPagos this facturas facturas this estado estado full constructor public DetallesPagos FormasPagos formasPagos Facturas facturas Double valor String descripcion String referenciaBancaria String numeroTransaccion String estado Date fechaRegistro Date fechaPago Date fechaActualizacion String observacion String usuarioIngreso this formasPagos formasPagos this facturas facturas this valor valor this descripcion descripcion this referenciaBancaria referenciaBancaria this numeroTransaccion numeroTransaccion this estado estado this fechaRegistro fechaRegistro this fechaPago fechaPago this fechaActualizacion fechaActualizacion this observacion observacion
112. l Set Xxx x Sucursales entity author MyEclipse Persistence Tools aes public class Sucursales implements java io Serializable Fields private Integer idSucursal 126 private Empresas empresas private String nombreSucursal private String direccion private String localidad private Dat chaRegistro private String observacion private String estado O Q OMh private String usuariolngreso private Date fechaActualizacion private Set empleadoses new HashSet 0 Constructors default constructor public Sucursales minimal constructor public Sucursales Empresas empresas String nombreSucursal Date fechaRegistro String estado his empresas empresas his nombreSucursal nombreSucursal his fechaRegistro fechaRegistro his estado estado ct ct ct ct full constructor public Sucursales Empresas empresas String nombreSucursal String direccion String localidad Date fechaRegistro String observacion String estado String usuariolngreso Date fechaActualizacion Set empleadoses his empresas empresas his nombreSucursal nombreSucursal his direccion direccion his localidad localidad his fechaRegistro fechaRegistro his observacion observacion his estado estado his usuariolngreso usuariolngreso his fechaActualizacion fechaActualizacion his emplead
113. l servidor web Apache Tomcat puede funcionar como servidor web por s mismo En sus inicios existi la percepci n de que el uso de Tomcat de forma aut noma era s lo recomendable para entornos de desarrollo y entornos con requisitos m nimos de velocidad y gesti n de transacciones Hoy en d a ya no existe esa percepci n y Tomcat es usado como servidor web aut nomo en entornos con alto nivel de tr fico y alta disponibilidad Dado que Tomcat fue escrito en Java funciona en cualquier sistema operativo que disponga de la m quina virtual Java 11 3 3 MySQL El software MySQL proporciona un servidor de base de datos SQL Structured Query Language muy rapido multi threaded multi usuario y robusto El servidor MySQL esta disenado para entornos de producci n criticos con alta carga de trabajo asi como para integrarse en software para ser distribuido El software tiene una doble licencia Los usuarios pueden elegir entre usar el Software MySQL como un producto Open Source bajo los t rminos de la licencia GNU General Public License http www fsf org licenses o pueden adquirir una licencia comercial estandar de MySQL AB CAPITULO 4 4 1 Codigo Fuente 4 et facturacionlsp2 4 58 src 4 H com general bo gt H LoginBO java Package com general bo CLASE QUE CONTIENE TODAS LAS VALIDACIONES
114. le 5nombrefile WHERE id producto Sidpro AND estado C dbh gt do sql5 sth5 dbh gt prepare sql5 sth5 gt execute Script Reserva usr bin perl use DBI datos RULE db DBI mysal facturacionisp 127 0 0 1 username root pass redes Sruta1 gt etc sysconfig cbq test open TEST ruta1 die No pudo abrirse dbh DBl gt connect db username pass 190 sql qq SELECT FROM servicios contratados WHERE estado R AND valor referencia 1 NULL AND valor referencia 2 NULL AND valor referencia 1 SERVCORREC dbh gt do sql sth dbh gt prepare sq sth gt execute while array sth gt fetchrow_array ip Sarray 8 contrato array 1 servicios array 0 iptables t nat A POSTROUTING o eth0 s ip 32 j MASQUERADE sq10 qq INSERT INTO nat ip VALUES Sip dbh gt do sq10 Ssth10 dbh gt prepare sq10 Ssth10 sexecute print UPDATE servicios contratados SET estado A WHERE estado R AND id servicio servicios AND id contrato contrato sq2 qq UPDATE servicios contratados SET estado A WHERE estado R AND id servicio servicios AND id contrato contrato dbh gt do sq2 Ssth1 dbh gt prepare sq2 sth1 gt execute print SELECT FROM contratos WHERE id contrato contrato sq3 qq SELECT
115. les this personas personas this tiposEmpleados tiposEmpleados this estado estado full constructor public Empleados Sucursales sucursales Personas personas Empleados empleados tiposEmpleados fechaFin Date fechaActualizacion String observacion TiposEmpleados Date fechalnicio Date fechaRegistro Date String estado String usuariolngreso Set contratoses Set empleadoses Set facturases his sucursales sucursales his personas personas his empleados empleados F his fechalnicio fechalnicio his fechaFin fechaFin his estado estado his observacion observacion his contratoses contratoses his empleadoses empleadoses his facturases facturases Gh Gh Gh CRP R ch GE Gt Gk Gh Ch Gh ER Property accessors public Integer getIdEmpleado return this idEmpleado public void setIdEmpleado Integer idi this idEmpleado idEmpleado public Sucursales getSucursales return this sucursales his tiposEmpleados tiposEmpleados his fechaRegistro fechaRegistro his fechaActualizacion fechaActualizacion his usuariolngreso usuariolngreso Empleado 85 public void setSucursales Sucursales sucursales this sucursales sucursales public Personas getPersonas re
116. lizacion fechaActualizacion this usuariolngreso usuariolngreso Property accessors public Integer getIdParametro return this idParametro public void setldParametro Integer idParametro this idParametro idParametro 118 public TiposParametros getTiposParametros return this tiposParametros public void setTiposParametros TiposParametros tiposParametros this tiposParametros tiposParametros public String getClaveParametro return this claveParametro public void setClaveParametro String claveParametro this claveParametro claveParametro public String getValorParametro return this valorParametro public void setValorParametro String valorParametro this valorParametro valorParametro public String getEstado return this estado public void setEstado String estado this estado estado public String getDescripcion return this descripcion public void setDescripcion String descripcion this descripcion descripcion public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public Date getFechaRegistro return this fechaRegistro 119 public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaActualizacion
117. m setObservacion Actualizacion de parametro param setUsuariolngreso Usuarios request get Session getAttribute Sesion USUARIO getDescUsuario param setFechaActualizacion new Date parameDao attachDirty param DAOUtil commit request getSession setAttribute MENSAJEOK n Actualizacion De Parametro Exitoso request getSession setAttribute PAGINA filConfigtacion do return mapping findForward ok catch Exception e DAOUtil rollback e printStackTrace request getSession setAttribute ERRORGENERAL e request getSession setAttribute TITULOERROR Error Actualizacion Parametro return mapping findForward fallo Generated by MyEclipse Struts Template path templates java JavaClass vtl aes package com general struts action 22 im im im im im port port port port Cs kda 12 1 ava util ava util HashMap Iterato ava util List ava util Set port javax serviet htt port javax serviet htt r p HttpServletRequest p HttpServletResponse import org apache struts action Action import org apache struts action ActionForm import org apache struts action ActionForward import org apache struts action ActionMapping import co
118. m general modelo persistentes Clientes import com general modelo persistentes Personas import com general modelo persistentes PersonasDAO import com general modelo persistentes Usuarios import com general modelo persistentes UsuariosDAO import com general util DAOUtil import com general util Operaciones import com general util Sesion import com general util ValidacionesVarias Xxx MyEclipse Struts Creation date 08 29 2009 XDoclet definition struts action validate true struts action forward name procesoFallido path sdsd redirect true struts action forward name procesoExitoso path sdsd redirect true El public class BuscarldentificacionClienteAction extends Action Generat Method param param param param A AER F F F N ed Methods execute mapping form request response return ActionForward public ActionForward execute ActionMapping mapping ActionForm form 23 HttpServletRequest request HttpServletResponse response TODO Auto generated method stub String principalError Error Crear Rol String datoldentificacion request getParameter datoldentificacion String accion request getParameter accion String lsGeneraUsuario boolean bandera false try String aux request getParameter aux accion accion null 0 accion request getSession setAttribute
119. ma width 35 gt lt bean message key etiquetas cambiarClave confirmacionClaveNueva gt lt td gt lt td class detalleForma gt lt html password property confirmacionClaveNueva maxlength 20 size 30 onfocus cambiarEstiloCajaTextoPass event on onblur cambiarEstiloCajaTextoPass event off styleClass cajaTextoPass onchange validarClaveNueva this gt lt html password gt lt td gt lt tr gt lt tr class pieForma gt lt td colspan 2 align center gt lt html submit value Guardar styleClass boton gt lt td gt lt tr gt lt table gt lt td gt lt tr gt lt table gt lt html form gt lt body gt lt html gt Gp META INF 4 f gt paginas 4 gt generales gt gt deluxe tree files P marquesina jsp lt page import com general modelo persistentes gt lt S page import java util gt lt Empresas empresa Empresas request getSession getAttribute EMPRESA List mensajesMarquesina List request getSession getAttribute PARAMETROSMAR if empresa null E empresa new Empresas empresa setRazonSocial BEMUSOFT oe V 182 lt html gt lt head gt lt title gt Marquesina con efecto disolvente lt title gt lt style gt etiquetasLink f text decoration underline Font size 9pt font
120. managed 71 transactions or they can be augmented to handle user managed Spring transactions Each of these methods provides additional information for how to configure it for the desired type of transaction control see com general modelo persistentes DetallesFacturas author MyEclipse Persistence Tools Pd public class DetallesFacturasDAO extends BaseHibernateDAO private static final Log log LogFactory getLog DetallesFacturasDAO class property constants public static final String DESCRIPCION descripcion public static final String VALOR_UNITARIO valorUnitario ublic static final String CANTIDAD cantidad ublic static final String SUBTOTAL subtotal ublic static final String VALOR_IVA valorlva ublic static final String VALOR ICE valorIce ublic static final String ESTADO estado ablic static final String OBSERVACION observacion public static final String USUARIO_INGRESO usuariolngreso D 30 10 10 00 public void save DetallesFacturas transientInstance log debug saving DetallesFacturas instance try getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete
121. minimal constructor public TiposParametros Integer idTipoParametro String estado this idTipoParametro idTipoParametro this estado estado full constructor public TiposParametros Integer idTipoParametro String descripcion String estado Date fechaRegistro String observacion Date fechaActualizacion String usuarioIngreso Set parametroses this idTipoParametro idTipoParametro this descripcion descripcion this estado estado this fechaRegistro fechaRegistro this observacion observacion 133 this fechaActualizacion fechaActualizacion this usuariolngreso usuariolngreso this parametroses parametroses Property accessors public Integer getIdTipoParametro return this idTipoParametro public void setIdTipoParametro Integer idTipoParametro this idTipoParametro idTipoParametro public String getDescripcion return this descripcion public void setDescripcion String descripcion this descripcion descripcion public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getObservacion return this observacion public void setObservacion String obs
122. n errorl Exception request getSession ST lt html gt lt head gt lt title gt BEMUSOFT V1 0 lt title gt lt meta http equiv Content Type 8859 1 gt lt style type text css gt lt permite la creacion de los lt gt body td th font family Verdana body margin left Opx margin top Opx getAttribute ERRORGENERAL content text html charset iso estilos en la pantalla del login gt Arial Helvetica sans serif 170 margin right Opx margin bottom Opx a link color FFFFFF text decoration none a visited text decoration none color FFFFFF a hover text decoration none color 80B7DE a active text decoration none color 00FF00 Estilo3 color white font weight bold font size 12px Estilod f font size 12px font weight bold color NAVY tablaLoggin background attachment scroll background image url imagenes marco gif background repeat no repeat background position center center Estilo7 color 175CB7 5 lt style gt lt Import de las clases y archivos para la pagina del login gt se importan los colores las validaciones y los efectos gt gt lt script type text javascript src lt request getContextPath gt js general js gt lt script gt lt link rel stylesheet href
123. navy distance of the scroller to the left margin of the browser window pixels var scrollerleft 10 distance of the scroller to the top margin of the browser window pixels var scrollertop 10 width of the scroller pixels var scrollerwidth 1200 height of the scroller pixels var scrollerheight 40 speed 1 lower means faster var pause 25 speed 2 higher means faster var step 2 font size var fntsize 14 font family var fntfamily Arial font weight 1 means bold 0 means normal var fntweight 1 do not edit the variables below var fadeimgwidth 40 var fadeimgleftcontent fadeimgrightcontent var clipleft clipright cliptop clipbottom var i_message 0 var timer var textwidth var textcontent if fntweight 1 fntweight 700 else fntweight 100 function init gettextcontent fadeimgleftcontent img src fadeimgleft gif 184 width fadeimgwidth height scrollerheight gt fadeimgrightcontent lt img src fadeimgright gif width fadeimgwidth height scrollerheight gt if document all text innerHTML textcontent fadeimgleft innerHTML fadeimgleftcontent fadeimgright innerHTML fadeimgrightcontent textwidth text offsetWidth document all text style posTop scrollertop document all text style posLeft scrollerleft scrollerwidth document all fadeimgleft style posTop scrollertop
124. nstances try String queryString from DetallesFacturas Query queryOb ject getSession createQuery queryString return queryObject list catch RuntimeException re log error find all failed re throw re public DetallesFacturas merge DetallesFacturas detachedInstance log debug merging DetallesFacturas instance try DetallesFacturas result DetallesFacturas getSession merge detachedInstance log debug merge successful return result catch RuntimeException re log error merge failed re throw re public void attachDirty DetallesFacturas instance log debug attaching dirty DetallesFacturas instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re 75 public LOS instance try LockMode NONI GI catch RuntimeException re throw re void attachClean DetallesFacturas instance debug attaching clean DetallesFacturas getSession lock instance log debug attach successful log error attach failed re throw re 4 facturacionlsp2 4 8 src gt MH com general bo E3 com general escuchadores gt D 8 com general filtros generales 4 3 com general modelo persistentes D DetallesPagos java package com general modelo persistentes import
125. o FUCNUC iii Es 12 CAPITULO 1 1 Manual T cnico 1 1 Introduccion El presente documento integra las normativas de caracter interno para que el personal adscrito en el Desarrollo lleve a cabo la elaboraci n de documentos administrativos que faciliten la capacitaci n y comprensi n en el uso y operaci n del sistema Bemusoft El desarrollo de Bemusoft ha permitido brindar una mejor distribuci n no solo con ofrecer un buen servicio de internet sino a la hora manejar un estricto y confiado control de la facturaci n como lo es la asignaci n exacta o correspondiente del ancho de banda de acuerdo al tipo de plan adquirido por el cliente as como tambi n mejoras de tiempo de respuesta en el proceso de facturaci n 1 2 Objetivos Generales del Sistema Brindamos informaci n confiable los datos son almacenados en repositorios ntegros capaces de manejar y procesar la informaci n de manera ptima manejando accesos inmediatos a la informaci n teniendo disponibilidad de la misma Brindamos un sistema medible capaz de procesar indicadores o variables para recolectar informes que permitan medir sus ndices de ventas o procesos internos 1 3 Objetivos espec ficos Disponemos de un servicio personalizado pensado en las necesidades del cliente capaz de que el sistema pueda acoplarse a las m ltiples posiciones sociales empresariales parametrizando los planes Agilitamos los flujos de algunos sistemas eliminado los
126. oid setUsuariolngreso String usuariolngreso this usuariolngreso usuariolngreso public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public Set getEmpleadoses return this empleadoses public void setEmpleadoses Set empleadoses this empleadoses empleadoses 4 g8 facturacionlsp2 4 58 src gt 8 com general bo E3 com general escuchadores gt A com general filtros generales 4 H com general modelo persistentes gt 1 TiposEmpleados java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx TiposEmpleados entity author MyEclipse Persistence Tools ng public class TiposEmpleados implements java io Serializable Fields private Integer idTipoEmpleado private String descripcionTipo private String estado private Date fechaRegistro private String observacion private Date fechaActualizacion private String usuariolngreso private Set empleadoses new HashSet 0 Constructors default constructor public TiposEmpleados minimal constructor public TiposEmpleados String descripcionTipo estado Date fechaRegistro this descripcionTipo descripcion
127. olor messagecolor i_message gt message i_message lt font gt lt nob r gt lt a gt lt span gt window onresize init End of JavaScript gt lt script gt lt style gt A text decoration none A Hover text decoration underline color 00224C body overflow x hidden overflow y scroll lt style gt lt head gt lt body onLoad init gt lt codigo java script para la marquesina se encuentra detallado abajo gt lt div ID text style position absolute left 2000px background color FFFFFE gt lt div gt lt div ID fadeimgleft gt lt div gt lt div ID fadeimgright style position absolute left 1000px gt lt div gt lt div id imagne align left gt 187 lt br gt lt div gt alae lt center gt lt font color navy size 6 gt hola mundo lt font gt lt center gt lt hr width 100 size 2 gt gt lt body gt lt html gt Herramientas para creacion de Scripts en Linux Script Planes Perl Esta basado en un estilo de bloques como los del C o AWK y fue ampliamente adoptado por su destreza en el procesado de texto y no tener ninguna de las limitaciones de los otros lenguajes de script Tiene caracteristicas que soportan una variedad de paradigmas de programaci n como la imperativa funcional y la orientada a objeros Al mismo tiempo no obliga a segui
128. on return this nombreOpcion public void setNombreOpcion String nombreOpcion this nombreOpcion nombreOpcion public String getRutaPagina return this rutaPagina public void setRutaPagina String rutaPagina this rutaPagina rutaPagina public String getEstado return this estado public void setEstado String estado this estado estado public String getAyuda return this ayuda public void setAyuda String ayuda this ayuda ayuda public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion 113 public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuarioIngreso public void setUsuarioIngreso String usuariolngreso this usuarioIngreso usuariolngreso public String getTarget return this target public void setTarget String target this target target public Set getOpcioneses return this opcioneses public void setOpcioneses
129. onstructors public String getCambioClave return cambioClave public void setCambioClave String cambioClave this cambioClave cambioClave default constructor public Usuarios minimal constructor public Usuarios Roles roles Personas personas String descUsuario String clave String estado his roles roles his personas personas his descUsuario descUsuario his clave clave his estado estado cot oct ct ct ct full constructor public Usuarios Roles roles Personas personas String descUsuario String clave String estado Date fechaRegistro String observacion String usuariolngreso Date fechaActualizacion Set loginUsuarioses this roles roles this personas personas 136 his descUsuario descUsuario his clave clave his estado estado his fechaRegistro fechaRegistro his observacion observacion his usuariolngreso usuariolngreso E his fechaActualizacion fechaActualizacion his loginUsuarioses loginUsuarioses AGE IESO GE Gh Gr Gt Property accessors public Integer getIdUsuario return this idUsuario public void setIdUsuario Integer idUsuario this idUsuario idUsuario public Roles getRoles return this roles public void setRoles Roles roles this roles roles public Personas getPersonas
130. ontratados correo setContratos cont correo setDescripcionServicio CORRI setEstado R Reservado setFechaRegistro new Date setObservacion observacion ED correo correo correo correo correo correo correo setUsuariol setProductos prod setFechal servDao save correo return cont EO ngreso user setValorReferencia3 CORREO nicio new Date Generated by My Template tol package com im im im im in in in in in in in in in in in in in port port port port port port port port port port port port port port port port port ava ava ava ava ava ava ava ava CG Ai ok Al tl de VJ ACI avax avax 139 134 NI UA org org org org a a a a avax avax avax Eclipse Struts path templates java JavaClass vtl general struts action io Unsupported security I Encoding nva security I nva lidKey security NoSuc security spec hAlgorit Exception idAlgorithmParameter Exception hm Exception util Date util List util Set Crypto crypto crypto NoSuchPadding servlet http HttpServl servlet http HttpServl Struts s SCEUS struts struts pache pache pache pache BadPadding IllegalBlockSi InvalidKeySpec Exception
131. ope request validate true struts action forward name ok path sdfdfdf redirect true struts action forward name fallo path dsfsd redirect true F public class ActualizarParametrosAction extends Action Generated Methods ay Method execute param mapping param form param request param response return ActionForward A AR F F F FSS public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response ActualizarParametrosForm actualizarParametrosForm ActualizarParametrosForm form TODO Auto generated method stub try if actualizarParametrosForm getValorParametro length x 1 throw new Exception Debe ingresar un valor para el parametro DAOUtil beginTransaction ParametrosDAO parameDao new ParametrosDAO Parametros param parameDao findByld new Integer actualizarParametrosForm getIdParametro param setValorParametro actualizarParametrosForm getV alorParametro toUpperCase if param getDescripcion equals IVA param getDescripcion equals ICE 21 try Float parseFloat actualizarParametrosForm getValorPar ametro catch Exception e throw new Exception El valor del parametro debe ser numerico para el impuesto de facturas para
132. os Empleados empleados this empleados empleados public CiclosFacturaciones getCiclosFacturaciones return this ciclosFacturaciones public void setCiclosFacturaciones CiclosFacturaciones ciclosFacturaciones this ciclosFacturaciones ciclosFacturaciones public Clientes getClientes return this clientes public void setClientes Clientes clientes this clientes clientes 60 public String getCuenta return this cuenta public void setCuenta String cuenta this cuenta cuenta public Date getFechalnicio return this fechalnicio public void setFechalnicio Date fechalnicio this fechalnicio fechalnicio public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public String getEstado return this estado public void setEstado String estado this estado estado public Date getFechaFin return this fechaFin public void setFechaFin Date fechaFin this fechaFin fechaFin public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion 61 public String getPlazo return this plazo public void setPlazo String
133. oses empleadoses Gh Eba Gr Gh AG TERA Gt Property accessors 127 public Integer getIdSucursal return this idSucursal public void setIdSucursal Integer idSucursal this idSucursal idSucursal public Empresas getEmpresas return this empresas public void setEmpresas Empresas empresas this empresas empresas public String getNombreSucursal return this nombreSucursal public void setNombreSucursal String nombreSucursal this nombreSucursal nombreSucursal public String getDireccion return this direccion public void setDireccion String direccion this direccion direccion public String getLocalidad return this localidad public void setLocalidad String localidad this localidad localidad public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro 128 public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getEstado return this estado public void setEstado String estado this estado estado public String getUsuarioIngreso return this usuariolngreso public v
134. p document all text style clip rect cliptop clipright clipbottom clipleft var timer setTimeout scrolltext pause else changetext if document layers if document text left gt scrollerleft textwidth document text left step document text clip right step if document text clip right gt scrollerwidth document text clip left step var timer setTimeout scrolltext pause else changetext function changetext i1 messagett if i_message gt message length 1 i message 0 gettextcontent if document all text innerHTML textcontent textwidth text offsetWidth document all text style posLeft scrollerleft scrollerwidth clipleft 0 clipright 0 document all text style clip rect cliptop clipright clipbottom clipleft scrolltext if document layers document text document write textcontent document text document close textwidth document text document width document text left scrollerleft scrollerwidth 186 document text clip left 0 document text clip right 0 scrolltext function gettextcontent textcontent lt span style position relative font size fntsize pt font family fntfamily font weight fntweight gt textcontent lt a href messageurl i_message target messagetarget i_message gt textcontent lt nobr gt lt font c
135. ping HttpServletRequest request TODO Auto generated method stub return null Xxx x Method reset x param mapping x param request public void reset ActionMapping mapping HttpServletRequest request TODO Auto generated method stub Xxx x Returns the fechaNacimiento x return String public String getFechaNacimiento return fechaNacimiento Xxx 156 Set the fechaNacimiento param fechaNacimiento The fechaNacimiento to set x public void setFechaNacimiento String fechaNacimiento this fechaNacimiento fechaNacimiento Xxx Returns the celular x return String EL public String getCelular return celular Xxx x Set the celular param celular The celular to set Bd public void setCelular String celular this celular celular Xxx x Returns the segundoNombre x return String public String getSegundoNombre return segundoNombre Xxx x Set the segundoNombre param segundoNombre The segundoNombre to set public void setSegundoNombre String segundoNombre this segundoNombre segundoNombre Xxx Returns the apellidoPaterno x return String SH public String getApellidoPaterno return apellidoPaterno Xxx 157 x Set the apellidoPaterno param apellidoPaterno The apellidoPaterno to set t4 public void setApellidoPaterno String apellidoPa
136. plazo this plazo plazo public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso public String getValorReferencial return this valorReferencial public void setValorReferencial String valorReferencial this valorReferencial valorReferencial public Set getFacturases return this facturases public void setFacturases Set facturases this facturases facturases public Set getServiciosContratadoses return this serviciosContratadoses public void setServiciosContratadoses Set serviciosContratadoses 62 this serviciosContratadoses serviciosContratadoses a f facturacionlsp2 4 58 src EB com general bo E3 com general escuchadores gt 8 com general filtros generales 4 H com general modelo persistentes 15 ContratosDAO java package com general modelo persistentes import java util Date import java util List import java util Set import org apache commons logging Log import org apache commons logging LogFactory import org hibernate LockMode import org hibernate Query import org hibernate criterion Example
137. r ningun paradigma en particular ni obliga al programador a elegir alguna de ellas Modulo DBI El m dulo DBI proporciona una forma unificada una API de acceder a las bases de datos es decir que independientemente del gestor de bases de datos que usemos usaremos las mismas funciones para hacer inserciones actualizaciones consultas etc Est n soportadas tanto bases de datos Open Source como Postgres miniSQL o MySQL como algunas comerciales como Oracle Sybase o Informix usr bin perl use DBI datos DEVICE eth0 10Mbit 1Mbit RATE WEIGHT PRIO 5 188 db DBI mysal facturacionisp 127 0 0 1 username root pass redes k Kbit sth3 gt execute FABRA H H fechadia localtime time valuesfecha split Sfechadia print values 1 values 2 values 4 Smesmag valuesfecha 1 if Smesmaq eq Jan mes 1 if Smesmaq eq Feb mes 2 if Smesmaq eq Mar mes 3 f 5mesmaq eq Apr mes 4 if Smesmaq eq May mes 5 if mesmagq eq Jun mes 6 f f f f f f if Smesmagq eq Jul mes 7 if mesmaq eq Agu mes 8 if Gmesmagq eq Sep mes 9 mesmag eq Oct mes 10 mesmaq eq Nov Smes 11 mesmaq eq Dec Smes 12 Sfecha2 Svaluesfecha 4 5mes 5valuesfecha 2 print Sfecha1 HHHHHHHHHHHHHHHHHHHHHHHHHHHHHHH HAHAHHAHAHA HAHAHHAHAHA dbh DBI gt
138. ram request param response return ActionForward si public ActionForward execute ActionMapping mapping ActionForm form HttpServletRequest request HttpServletResponse response TODO Auto generated method stub try Roles rol Roles request getSession getAttribute ROL_ENC String idOpcion request getParameter idOpcion DAOUtil beginTransaction j RolesDAO rolDao new RolesDAO Roles roll rolDao findById rol getIdRol OpcionesDAO opcDao new OpcionesDAO Opciones opc opcDao findById new Integer idOpcion Set opcionesR01 roll getOpcionesRoleses Iterator ite opcionesROl iterator OpcionesRoles opsRolFinal null OpcionesRolesDAO ocoDao new OpcionesRolesDAO while ite hasNext OpcionesRoles opsRol OpcionesRoles ite next if opsRol getOpciones getIdOpcion toString equals opc get TdOp cion toString opsRolFinal opsRol break if opsRolFinal null actualizar con estado A opsRolFinal setFechaActualizacion new Date opsRolFinal setObservacion Activacion De Opcion Desde La Aplicacion opsRolFinal setUsuariolngreso Usuarios request getSessi on getAttribute Sesion USUARIO getDescUsuario opsRolFinal setEstado A 147 La Aplicacion ocoDao attachDirty opsRolFinal else c
139. re public void attachClean Empresas instance log debug attaching clean Empresas instance try getSession lock instance LockMode NONE log debug attach successful catch RuntimeException re log error attach failed re throw re a gt facturacionlsp2 4 58 src gt AH com general bo gt EH com general escuchadores gt 8 com general filtros generales 4 H com general modelo persistentes gt IN EstadosFacturas java package com general modelo persistentes import java util Date public class EstadosFacturas implements java io Serializable Fields private Integer idEstado private String descripcion private String valor private Date fechaRegistro private Date fechaActualizacion private String observacion private String estado private String usuarioIngreso 92 Constructors default constructor public EstadosFacturas minimal constructor public EstadosFacturas String estado this estado estado full constructor public EstadosFacturas String descripcion String valor Date fechaRegistro Date fechaActualizacion String observacion String estado String usuariolngreso this descripcion descripcion this valor valor this fechaRegistro fechaRegistro this fechaActualizacion fechaActualizacion this observacion observacion this estado estado this usuariolngreso us
140. rear un registro opsRolFinal new OpcionesRoles opsRolFinal setEstado A opsRolFinal setFechaRegistro new Date opsRolFinal setObservacion Creacion Desde opsRolFinal setOpciones opc opsRolFinal setRoles roll opsRolFinal setUsuariolngreso Usuarios request getSessi on getAttribute Sesion USUARIO getDescUsuario modulosRol iterator ocoDao save opsRolFinal roll rolDao findById rol getIdRol obtener los modulos padres del rol Vector modulosPadresAsignados new Vector Set modulosRol roll getOpcionesRoleses Iterator modulosAsigandos Modulos Asignados while modulosAsigandos hasNext OpcionesRoles opcionesRol OpcionesRoles modulosAsigandos next if opcionesRol getEstado equals A Opciones opcion opcionesRol getOpciones if opcion getOpciones null f opcion getEstado equals A modulosPadresAsignados add opcion Modulos no asigandos OpcionesDAO opcionesDAo new OpcionesDAO Vector modulosNoAsigandos new Vector List opciones opcionesDAo findByProperty opcionesDAo ESTADO A 148 Iterator modulosNAsig opciones iterator int bandera 0 while modulosNAsig hasNext Opciones opcionl Opciones modulosNAsig next bandera 0 if opc
141. return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getUsuarioIngreso return this usuariolngreso public void setUsuarioIngreso String usuariolngreso this usuariolngreso usuariolngreso 4 H facturacionlsp2 48 src gt M com general bo E com general escuchadores gt MH com general filtros generales 4 8 com general modelo persistentes b J ProvisionaActivacionPlan java package com general modelo persistentes import java util Date Xxx x ProvisionaActivacionPlan generated by MyEclipse Persistence Tools af public class ProvisionaActivacionPlan implements java io Serializable Fields private Integer idAprovisiona private String codiPlan private String valorMaxPlan private String estado 120 private Date fechaRegistro private Date fechaActualiza private String requerimiento private String respuesta private String usuarioIngreso private String usuarioDespacha private String accion Constructors default constructor public ProvisionaActivacionPlan full constructor public ProvisionaActivacionPlan String codiPlan valorMaxPlan String estado Date fechaRegistro Date fechaActualiza String requerimiento String respuesta usuarioIngreso String usuarioDespacha String accion this codiPlan codiPl
142. sFacturasDAO java package com general modelo persistentes import java util Date import java util List import org apache commons logging Log import org apache commons logging LogFactory 94 import org hibernate LockMode import org hibernate Query import org hibernate criterion Example Xxx A data access object DAO providing persistence and search support for EstadosFacturas entities Transaction control of the save update and le delete operations can directly support Spring container managed x transactions or they can be augmented to handle user managed Spring transactions Each of these methods provides additional information for how to configure it for the desired type of transaction control see com general modelo persistentes EstadosFacturas author MyEclipse Persistence Tools EL public class EstadosFacturasDAO extends BaseHibernateDAO private static final Log log LogFactory getLog EstadosFacturasDAO class property constants public static final String DESCRIPCION descripcion public static final String VALOR valor public static final String OBSERVACION observacion public static final String ESTADO estado public static final String USUARIO_INGRESO usuarioIngreso public void save E
143. ss size 19 gt lt td gt lt td gt lt tr gt lt tr valign middle gt lt td gt lt td gt lt td colspan 2 align center valign middle gt lt br gt 173 lt input type Reset value Cancelar class boton gt nbsp nbsp lt html submit value Ingresar styleClass boton gt lt td gt lt td gt lt td gt lt tr gt lt tr gt lt td gt lt td gt lt td height 18 colspan 3 gt lt DWLayoutEmpt yCell gt amp nbsp lt td gt lt td gt lt td gt lt tr gt lt tr gt lt td gt lt td gt lt td height 1 gt lt td gt lt td width 99 gt lt td gt lt td gt lt td gt lt td gt lt td gt lt tr gt lt table gt lt fieldset gt lt td gt lt td gt nbsp lt td gt lt tr gt lt tr gt lt td height 18 gt snbsp lt td gt lt td gt amp nbsp lt td gt lt td gt amp nbsp lt td gt lt tr gt lt table gt lt table width 100 height 60 border 0 cellpadding 0 cellspacing 0 background images rayamitad gif bgcolor white gt lt DWLayoutTable gt lt tr gt lt td width 100 height 254 valign middle gt lt div align center gt lt img src imagenes bemusSoft JPG gt lt img gt lt div gt lt td gt lt tr gt lt table gt lt html form gt lt body gt lt html gt lt page language java pageEncoding IS0 8859 1 gt lt taglib uri http
144. stadosFacturas transientInstance log debug saving EstadosFacturas instance try getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete EstadosFacturas persistentInstance 95 log debug deleting EstadosFacturas instance try getSession delete persistentInstance log debug delete successful catch RuntimeException re log error delete failed re throw re public EstadosFacturas findById java lang Integer id log debug getting EstadosFacturas instance with irde o ANTON try EstadosFacturas instance EstadosFacturas getSession get com general modelo persistentes EstadosFacturas id return instance catch RuntimeException re log error get failed re throw re public List findByExample EstadosFacturas instance log debug finding EstadosFacturas instance by example try List results getSession createCriteria com general modelo persistentes EstadosFacturas a dd Example create instance list log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String property
145. t nombreCompletos gt onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off styleClass cajaTexto readonly true rows 2 cols 31 gt lt html errors property descripcionRol gt lt td gt 177 lt tr gt lt tr gt lt td class etiquetaForma width 20 gt Usuario lt td gt lt td class detalleForma width 30 gt lt html hidden property idPersona value lt 1dPersona gt gt lt html errors property idPersona gt lt html text property descripcionUsuario value lt S usuario toUpperCase 35 onfocus cambiarEstiloCajaTexto event on onblur cambiarEstiloCajaTexto event off styleClass cajaTexto readonly true gt lt html errors property descripcionUsuario gt lt td gt lt td class etiquetaForma width 20 gt Rol lt td gt lt td class detalleForma width 30 gt lt html hidden property idPersona gt lt html errors property idPersona gt lt html select property rol onfocus cambiarEstiloCombo event on onblur cambiarEstiloCombo event off styleClass combo gt lt html option value 1 gt SELECCIONE lt html option gt lt html options collection ROLESSISTEMAS property idRol labelProperty descRol gt lt html select gt lt html errors property rol gt lt td gt
146. t MH com general filtros generales 4 8 com general modelo persistentes gt D Parametros java package com general modelo persistentes import java util Date Xxx x Parametros generated by MyEclipse Persistence Tools 7 public class Parametros implements java io Serializable Fields private Integer idParametro private TiposParametros tiposParametros private String claveParametro private String valorParametro 117 private String estado private String descripcion private String observacion private Date fechaRegistro private Date fechaActualizacion private String usuarioIngreso Constructors default constructor public Parametros minimal constructor public Parametros Integer idParametro TiposParametros tiposParametros this idParametro idParametro this tiposParametros tiposParametros full constructor public Parametros Integer idParametro TiposParametros tiposParametros String claveParametro String valorParametro String estado String descripcion String observacion Date fechaRegistro Date fechaActualizacion String usuariolngreso this idParametro idParametro this tiposParametros tiposParametros this claveParametro claveParametro this valorParametro valorParametro this estado estado this descripcion descripcion this observacion observacion this fechaRegistro fechaRegistro this fechaActua
147. tado this idOpcion idOpcion this descOpcion descOpcion this estado estado full constructor Opciones Integer idOpcion Opciones opciones public 111 String descOpcion String nombreOpcion String rutaPagina estado String ayuda Date fechaRegistro observacion Date fechaActualizacion usuarioIngreso String target Set opcioneses Set opcionesRoleses his idOpcion idOpcion his opciones opciones his descOpcion descOpcion his nombreOpcion nombreOpcion his rutaPagina rutaPagina his estado estado his ayuda ayuda his fechaRegistro fechaRegistro his observacion observacion his fechaActualizacion fechaActualizacion his usuariolngreso usuariolngreso his target target his opcioneses opcioneses his opcionesRoleses opcionesRoleses Gh ahs aie Yat ch CL Gr q O E Gerr EL esta ets US Property accessors public Integer getIdOpcion return this idOpcion public void setIdOpcion Integer idOpcion this idOpcion idOpcion public Opciones getOpciones return this opciones public void setOpciones Opciones opciones this opciones opciones public String getDescOpcion return this descOpcion public void setDescOpcion String descOpcion this descOpcion descOpcion String String String 112 public String getNombreOpci
148. tance try getSession lock instance LockMode NONE log debug attach successful catch RuntimeException re log error attach failed re throw re 4 igo facturacionls 4 58 src 83 p2 gt 8 com general bo FH com general escuchadores gt M com general filtros generales 4 FB com general modelo persistentes gt J Empleados java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx x Empleados entity author MyEclipse Persistence Tools public class Empleados implements java io Serializable Fields private Integer idEmpleado private Sucursales sucursales private Personas personas private Empleados empleados private TiposEmpleados tiposEmpleados private Date fechalnicio private Date fechaRegistro private Date fechaFin private Date fechaActualizacion private String estado private String observacion private String usuariolngreso private Set contratoses new HashSet 0 private Set empleadoses new HashSet 0 private Set facturases new HashSet 0 Constructors default constructor public Empleados minimal constructor public Empleados Sucursales sucursales Personas 84 personas TiposEmpleados tiposEmpleados String estado this sucursales sucursa
149. terno this apellidoPaterno apellidoPaterno Xxx x Returns the cedula return String Ba public String getCedula return cedula Xxx x Set the cedula x param cedula The cedula to set EL public void setCedula String cedula this cedula cedula Xxx x Returns the ruc x return String A public String getRuc return ruc Xxx x Set the ruc param ruc The ruc to set El public void setRuc String ruc this ruc ruc Xxx x Returns the observacion x return String public String getObservacion return observacion Xxx 158 Set the observacion param observacion The observacion to set wy public void setObservacion String observacion this observacion observacion Xxx x Returns the primerNombre x return String a public String getPrimerNombre return primerNombre Xxx x Set the primerNombre x param primerNombre The primerNombre to set tj public void setPrimerNombre String primerNombre this primerNombre primerNombre Xxx Returns the apellidoMaterno x return String Ef public String getApellidoMaterno return apellidoMaterno Xxx x Set the apellidoMaterno param apellidoMaterno The apellidoMaterno to set public void setApellidoMaterno String apellidoMaterno this apellidoMaterno apellidoMaterno Xxx x Returns the email x return String
150. tiempos de Improductividad que conlleven a un retardo en el procesamiento de la informaci n generando concurrencia que no pueda ser atendida a tiempo Nuestro sistema y personal est en la capacidad de brindar o crear reglas de negocio para lograr o crear est ndares aplicables en los m ltiplos usuarios y tener un mejor control sobre los procesos Brindamos escalabilidad capaz de brindar servicios aun en mercados en crecimiento CAPITULO 2 2 Contenido t cnico 2 1 Reglas del Negocio e Elcliente ISP podra parametrizar e Activaci n inactivaci n del usuario ademas de poder Resetear la claves e Optar por generar o ingresar manualmente el c digo de los productos Planes de internet y podra decidir que prefijo acompa a el c digo autom tico e Ingresar el ciclo de facturaci n que mejor se adapte a sus necesidades e Ingresar el rango de facturas f sicas para generar facturas informativas para sus clientes cabe recalcar que dichas facturas no tienen validez jur dica e El sistema realiza una facturaci n basado en impuestos vigentes si en el futuro se incluyera otro impuesto por cuestiones gubernamentales deber n contactarse con Bemusoft S A para su respectiva modificaci n e Como regla se ofrecer un plan por contrato y el servicio a un ordenador por plan El cliente final podra renunciar al servicio de internet si y solo si no mantiene deuda alguna con su ISP en caso de que renuncie antes de term
151. tion IllegalBlocksizeFxception BadPaddingException IOException return desencriptar CLAVE str public static void main String arg throws Exception ZtHInAGUOO8 System out printin desencriptar BG9I1tPU3tGj78djwYxuJdg package com general util import java io BufferedReader import java io FileNotFoundException import java io FileReader import java util Vector 163 import com general modelo persistentes Datoslp public class UtilLeeDhcp public static Vector leerDhcp throws Exception Vector vec new Vector String file Z dhcpd leases String texto FileReader fr new FileReader file BufferedReader entrada new BufferedReader fr String s int flag 0 String auxiliar String ip String mac while s entrada readLine null WT LA System out printin s if s toUpperCase indexOf LEASE I 1 s toUpperCase indexOf HARDWARE ETHERNET 1 if s toUpperCase indexOf LEASE IS 1 f if s toUpperCase indexOf 1 auxiliar s Ain flag 1 if flag 1 if s toUpperCase indexOf HARDWARE ETHERNET 1 1 flag 2 if s toUpperCase indexOf bh f if flag 2 f if auxil
152. tratos private Clientes clientes private String numeroFactura private Date fechaRegistro private Date fechaFactura private Double subTotal private Double totallva private Double totallce private Integer totalltem private Double totalDescuento private String estado private Date fechaActualizacion private String observacion private String usuariolngreso private Set detallesPagoses new HashSet 0 private Set detallesFacturases new HashSet 0 Constructors default constructor public Facturas 99 minimal constructor public Facturas Empleados empleados Clientes clientes String numeroFactura String estado this empleados empleados this clientes clientes this numeroFactura numeroFactura this estado estado full constructor public Facturas Empleados empleados Contratos contratos Clientes clientes String numeroFactura Date fechaRegistro Date fechaFactura Double subTotal Double totallva Double totallce Integer totalltem Double totalDescuento String estado Date fechaActualizacion String observacion String usuariolngreso Set detallesPagoses Set detallesFacturases this empleados empleados his contratos contratos his clientes clientes his numeroFactura numeroFactura his fechaRegistro fechaRegistro his f
153. tratos instance try A getSession delete persistentInstance log debug delete successful catch RuntimeException re log error delete failed re throw re public Contratos findByld java lang Integer id log debug getting Contratos instance with id id try Contratos instance Contratos getSession get com general modelo persistentes Contratos id return instance catch RuntimeException re log error get failed re throw re public List findByExample Contratos instance log debug finding Contratos instance by example try 64 List results getSession createCriteria com general modelo persistentes Contratos add Example create instance list log debug find by example successful result size results size return results catch RuntimeException re log error find by example failed re throw re public List findByProperty String propertyName Object value log debug finding Contratos instance with property propertyName value value try String queryString from Contratos as model where model propertyName Query queryObject getSession createQuery queryString queryObject setParameter 0 value return queryObject list catch RuntimeException re log error find by property name
154. tro new Date usuario setObservacion ingresoUsuarioForm getObserva 40 cion toUpperCase usuario setUsuariolngreso descUsuario toUpperCase usuario setPersonas pers usuario setRoles rolesDao findById new Integer ingresoUsuarioForm getRo1 usuario setClave UtilCryptography encriptar 12345678 usuarioDao save usuario ES facturacionlsp2 4 8 src gt MH com general bo EH com general escuchadores EB com general filtros generales 4 H com general modelo persistentes gt I BaseHibernateDAO java gt M CiclosFacturaciones java IJ CiclosFacturacionesDAO java FECHA 20 06 2009 AUTOR GRUPO 3 SESSIONES DE HIBERNATE GI SE BORRA ESTA CLAS CLASES PERSISTENTES ESTO LO GENERA EL Persistence Tools COMENTARIO CLASE QUE SE ENCARGA DE package com general modelo persistentes SALDRA ERROR EN CADENA DE LOS DAOS DE CAI r DE ESTA CLASE HEREDAN LAS CLASES DAO DE CADA TAI DA UNA BLA D T DA DE MY ECL PSE x x import org hibernate Session import com general util DAOUtil DESPACHAR LAS SI LAS 41 Xxx x Data access object DAO for domain model author MyEclipse Persistence Tools a public class BaseHibernateDAO implements IBaseHibernateDAO
155. turn this personas public void setPersonas Personas personas this personas personas public Empleados getEmpleados return this empleados public void setFmpleados Empleados empleados this empleados empleados public TiposEmpleados getTiposEmpleados return this tiposEmpleados public void setTiposEmpleados TiposEmpleados tiposEmpleados this tiposEmpleados tiposEmpleados public Date getFechalnicio return this fechaInicio public void setFechalnicio Date fechalnicio this fechalnicio fechalnicio public Date getFechaRegistro return this fechaRegistro public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaFin return this fechaFin 86 public void setFechaFin Date fechaFin this fechaFin fechaFin public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getEstado return this estado public void setEstado String estado this estado estado public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String
156. ualizacion fechaActualizacion Property accessors public Integer getIdDetalle return this idDetalle public void setIdDetalle Integer idDetalle this idDetall idDetalle public Productos getProductos return this productos public void setProductos Productos productos this productos productos public Facturas getFacturas return this facturas public void setFacturas Facturas facturas this facturas facturas public String getDescripcion return this descripcion public void setDescripcion String descripcion this descripcion descripcion public Double getValorUnitario return this valorUnitario 69 public void setValorUnitario Double valorUnitario this valorUnitario valorUnitario public Integer getCantidad return this cantidad public void setCantidad Integer cantidad this cantidad cantidad public Double getSubtotal return this subtotal public void setSubtotal Double subtotal this subtotal subtotal public Double getValorIva return this valorIva public void setValorIva Double valorIva this valorIva valorlva public Double getValorIce return this valorIce public void setValorIce Double valorIce this valorIce valorIce public String getEstado return this estado public void s
157. uariolngreso Property accessors public Integer getIdEstado return this idEstado public void setIdEstado Integer idEstado this idEstado idEstado public String getDescripcion return this descripcion public void setDescripcion String descripcion this descripcion descripcion public String getValor return this valor public void setValor String valor this valor valor public Date getFechaRegistro return this fechaRegistro 93 public void setFechaRegistro Date fechaRegistro this fechaRegistro fechaRegistro public Date getFechaActualizacion return this fechaActualizacion public void setFechaActualizacion Date fechaActualizacion this fechaActualizacion fechaActualizacion public String getObservacion return this observacion public void setObservacion String observacion this observacion observacion public String getEstado return this estado public void setEstado String estado this estado estado public String getUsuarioIngreso return this usuariolngreso public void setUsuariolngreso String usuariolngreso this usuariolngreso usuariolngreso 4 ES facturacionlsp2 4 58 src gt M com general bo EB com general escuchadores gt H com general filtros generales 4 FH com general modelo persistentes gt J Estado
158. uarioses Set loginUsuarioses this loginUsuarioses loginUsuarioses 4 7 facturacionlsp2 a G src gt MH com general bo FH com general escuchadores gt MH com general filtros generales 4 H com general modelo persistentes gt 5 Opciones java package com general modelo persistentes import java util Date import java util HashSet import java util Set Xxx 110 Opciones entity author MyEclipse Persistence Tools my public class Opciones implements java io Serializable Fields private private private private private private private privat Integer idOpcion Opciones opciones String descOpcion String nombreOpcion String rutaPagina String estado String ayuda MQAaQQQa private private private private private private private Dat chaRegistro String observacion Date fechaActualizacion String usuariolngreso String target Q Set opcioneses new HashSet 0 Set opcionesRoleses new HashSet 0 Integer ordenPresentacion Constructors public Integer getOrdenPresentacion return ordenPresentacion public void setOrdenPresentacion Integer ordenPresentacion this ordenPresentacion ordenPresentacion default constructor public Opciones minimal constructor Opciones Integer idOpcion String descOpcion public String es
159. ublic void reset ActionMapping mapping HttpServletRequest request TODO Auto generated method stub Xxx x Returns the fecha return String x public String getFecha return fecha Xxx x Set the fecha x param fecha The fecha to set el public void setFecha String fecha this fecha fecha Xxx x Returns the ciclo return String public String getCiclo return ciclo Xxx x Set the ciclo param ciclo The ciclo to set aY 153 public void setCiclo String ciclo this ciclo ciclo Generated by MyEclipse Struts Template path templates java JavaClass vtl 7 package com general struts form import Javax servlet http HttpServletRequest import org apache struts action ActionErrors import org apache struts action ActionForm import org apache struts action ActionMapping Xxx x MyEclipse Struts x Creation date 08 01 2009 XDoclet definition struts form name ingresoPersonasForm ES public class IngresoClientesForm extends ActionForm Generated fields Ef fechaNacimiento property private String fechaNacimiento celular property private String celular segundoNombre property private String segundoNombre sexo property private String tipoPersona apellidoPaterno property private String apellidoPaterno ce
160. ublicas modulo 11 Aqui el digito verficador esta en la posicion 9 en las otras 2 167 en la pos 10 if d3 6 publica true pl dl 3 p2 d2 2 ps AN Ti p4 d4 6 p5 A5 5 p6 d6 4 pi Cd A 34 p8 d8 2 p9 0 Solo para entidades privadas modulo 11 if d3 9 privada true pl dl 4 p2 d2 3 p3ba d3 2 p4 d4 7 p5 d5 6 p6 d6 5 p7 d7 4 p8 d8 3 p9 d9 2 suma pl p2 p3 p4 po pb pl p8 p9 residuo suma modulo Si residuo 0 dig ver 0 caso contrario 10 residuo digitoVerificador residuo 0 0 modulo residuo int longitud numero length Longitud del string ahora comparamos el elemento de la posicion 10 con el dig ver if publica true if digitoVerificador d9 valor false throw new Exception El ruc de la empresa del sector publico es incorrecto El ruc de las empresas del sector publico terminan con 0001 if numero substring 9 longitud equals 0001 valor false throw new Exception El ruc de 168 la empresa del sector publico debe terminar con 0001 if privada true if digitoVerificador d10 valor false throw new Exception El la empresa del sector privado es incorrecto if numero substring 10 longitud equals
161. ug finding all Clientes instances try String queryString from Clientes Query queryObject getSession createQuery queryString return queryObject list catch RuntimeException re log error find all failed re O 56 throw re public Clientes merg log debug mergin try Clientes detachedInstance g Clientes instance Clientes result getSession merge detachedInstance log debug merge successful return result catch Runtime log error throw re Clientes Exception re merge failed re public void attachDirty Clientes instance log debug attaching dirty Clientes instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed throw re re public void attachClean Clientes instance log debug attaching clean Clientes instance try 4 getSession lock instance LockMode NONE log debug attach successful catch RuntimeException re log error attach failed throw re re a ES facturacionlsp2 4 58 src EB com general bo 8 com general escuchadores 8 com general filtros generales 4 FH com general modelo persistentes 47 Contratos java 57 package com general modelo persistentes AUTOR GRUPO y
162. upport for x CiclosFacturaciones entities Transaction control of the save update and ng delete operations can directly support Spring container managed x transactions or they can be augmented to handle user managed Spring x transactions Fach of these methods provides additional information for how to configure it for the desired type of transaction control see com general modelo persistentes CiclosFacturaciones author MyEclipse Persistence Tools Ay public class CiclosFacturacionesDAO extends BaseHibernateDAO private static final Log log LogFactory getLog CiclosFacturacionesDAO class property constants public static final String DESCRIPCION_CICLO descripcionCiclo public static final String ESTADO estado public static final String OBSERVACION observacion public static final String USUARIO_INGRESO usuarioIngreso public void save CiclosFacturaciones transientInstance log debug saving CiclosFacturaciones instance try 4 getSession save transientInstance log debug save successful catch RuntimeException re log error save failed re throw re public void delete CiclosFacturaciones persistentInstance log debug deleting CiclosFacturaciones 46 instance try getSession delete persistentInstance log
163. weight bold color 00224C letter spacing 1px font family Arial color 00224C font weight bold vertical align top backFrame f background color 999999 lt style gt lt lt p align center gt lt b gt lt font class etiquetasLink gt Anuncios lt font gt lt b gt lt br gt lt p gt gt lt script LANGUAGE JavaScript gt Edit the variables below Your messages Add as many as you like var message new Array message 0 Sistema De Facturacion Y Administracion De ISP Gestion En La Empresa lt S empresa getRazonSocial toUpperCase 375 message 1 Grupo De Seminario Tema REDES the URLs of your messages var messageurl new Array messageur1 0 http service bfast com bfast click bfmid 7279965 siteid 30125004 amp bfpage webclipart3 messageurl 1 http service bfast com bfast click bfmid 7279965 amp si teid 30125004gbfpage javascript messageurl 2 http service bfast com bfast click bfmid 599904 sit eid 30259589k amp bfpage gifbot the targets of the links accepted values are _blank or _top or _parent or _self or the name of your target window for instance main var messagetarget new Array messagetarget 0 _blank messagetarget 1 _blank 183 messagetarget 2 _blank font color var messagecolor new Array messagecolor 0 navy messagecolor 1
164. y Contratos instance log debug attaching dirty Contratos instance try getSession saveOrUpdate instance log debug attach successful catch RuntimeException re log error attach failed re throw re 66 public void attachClean Contratos instance log debug attaching clean Contratos instance try getSession lock instance LockMode NONE log debug attach successful catch RuntimeException re log error attach failed re throw re ES facturacionlsp2 4 3 src gt 8 com general bo gt 8 com general escuchadores gt 8 com general filtros generales 4 H com general modelo persistentes U Datoslp java package com general modelo persistentes public class DatosIp String ip String mac public String getIp return ip public void setIp String ip this ip ip public String getMac return mac public void setMac String mac this mac mac 4 f facturacionlsp2 4 src gt AH com general bo gt HH com general escuchadores gt MH com general filtros generales 4 H com general modelo persistentes gt J DetallesFacturas java 67 package com general modelo persistentes import java util Date Xxx x DetallesFacturas entity author MyEclipse Persistence Tools public class DetallesFacturas implements java io Serializable Fields private

Download Pdf Manuals

image

Related Search

Related Contents

Manhattan 421874  pdf - Amarr® Garage Doors  Braun Photo Technik Arica  Manual del usuario  Service Manual  Istruzioni per l`uso  IFU for GC Fuji IX GP EXTRA pg 1  JVC HR-J277MS User's Manual  Clarion 935VD User's Manual  ETX Feature Connector Adaptor ADA  

Copyright © All rights reserved.
Failed to retrieve file