Edit C:\Users\Administrator\Desktop\Back\Livraison EVQG22\com\edeal\frontline\tasks\action\custom\TauxGenerositeToCevTransmissionTask_Helper.class
Êþº¾ 3° Rcom/edeal/frontline/tasks/action/custom/TauxGenerositeToCevTransmissionTask_Helper java/lang/Object logger Lorg/apache/commons/logging/Log; <clinit> ()V Code %org/apache/commons/logging/LogFactory getLog 3(Ljava/lang/Class;)Lorg/apache/commons/logging/Log; LineNumberTable LocalVariableTable <init> this TLcom/edeal/frontline/tasks/action/custom/TauxGenerositeToCevTransmissionTask_Helper; generateTauxGenFileAndGetPath E(Lcom/edeal/frontline/FlContext;Ljava/lang/String;)Ljava/lang/String; Exceptions &com/edeal/frontline/FrontlineException java/io/IOException ! java/util/Vector $ idHotel & idAdherent ( taux * dateDebut , dateFin . ; 0 2 TAUX.GENEROSITE.FILENAME 4 6 5 com/edeal/frontline/FlContext 7 8 getContextParameter &(Ljava/lang/String;)Ljava/lang/String; : < ; java/lang/Exception = > getMessage ()Ljava/lang/String; @ B A org/apache/commons/logging/Log C D error (Ljava/lang/Object;)V F TauxGenerosite-{TODAY_DATE}.csv H {TODAY_DATE} J java/text/SimpleDateFormat L yyyyMMddHHmmss I N O (Ljava/lang/String;)V Q java/util/Date P I T U V format $(Ljava/util/Date;)Ljava/lang/String; X Z Y java/lang/String [ \ replace D(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String; ^ java/lang/StringBuilder ] a u SELECT EntHotelID_ as "idHotel",Ct_CodeContrat || '' as "idAdherent", replace(r3.RefNu1 || '', '.', ',') as "taux", ] c d e append -(Ljava/lang/String;)Ljava/lang/StringBuilder; g a to_char(Gt_DateDebut,'DD/MM/YYYY') as "dateDebut",to_char(Gt_DateFin,'DD/MM/YYYY') as "dateFin" i FROM Contrat_ k . inner join Signataire_ ON Sg_Contrat = Ct_ID m , inner join MvaSg_Tiers ON MvaColID = Sg_ID o * inner join Enterprise ON EntID = MvaText q 1 inner join Refvalues r1 on r1.RefID = Ct_Statut s 6 inner join Refvalues r2 on r2.RefID = Ct_TypeContrat u 0 inner join TauxGenerosite_ on Gt_EntID = EntID w 9 inner join RefValues r3 on r3.RefID = Gt_TauxHotelRefID y ) WHERE r2.RefVal not in ('QT','PT','FA') { ? AND ( r1.RefVal = 'VAL' OR r1.RefVal='EAV' OR r1.RefVal='RAD') } 1 AND ( Ct_DateFin IS NULL OR Ct_DateFin > NOW() ) ? AND Ct_CodeContrat IS NOT NULL AND Ct_ContratPrincipal IS NULL X ? ? ? length ()I X ? ? > toUpperCase X ? ? ? charAt (I)C ? ? ? java/util/Calendar ? ? getInstance ()Ljava/util/Calendar; ? ? ? ? setTime (Ljava/util/Date;)V ? ? ? ? add (II)V ? ? ? ? get (I)I X ? ? valueOf (I)Ljava/lang/String; ] N ] £ ¤ > toString ¦ TAUX.GENEROSITE.CEV.EXPORTDATE ¨ YYYY-MM-25 00:00:00 ª MM ¬ YYYY ® AND Gt_Upd > ' ° ' ² ORDER BY "idHotel", "dateDebut" ´ 7[TauxGenerositeToCevTransmissionTask_Helper] sql query: ] ¶ d · -(Ljava/lang/Object;)Ljava/lang/StringBuilder; @ ¹ º D info ¼ ¾ ½ 'com/edeal/frontline/custom/Contrat_Bean ¿ À listSQL X(Lcom/edeal/frontline/FlContext;[Ljava/lang/String;Ljava/lang/String;)Ljava/util/Vector;  à ? size Å java/io/BufferedWriter Ç java/io/OutputStreamWriter É java/io/FileOutputStream È N Ì UTF-8 Æ Î Ï +(Ljava/io/OutputStream;Ljava/lang/String;)V Ä Ñ Ò (Ljava/io/Writer;)V Ô java/lang/StringBuffer Ó × idHotel; Ó Ù d Ú ,(Ljava/lang/String;)Ljava/lang/StringBuffer; Ü idAdherent; Þ taux; à dateDebut; â dateFin Ó £ Ä å æ O write Ä è é flush ë ì í elementAt (I)Ljava/lang/Object; ï java/util/Hashtable î ñ ? ò &(Ljava/lang/Object;)Ljava/lang/Object; X ô ? õ &(Ljava/lang/Object;)Ljava/lang/String; Ä ÷ ø close context Lcom/edeal/frontline/FlContext; PROCESS_ALL Ljava/lang/String; cts Ljava/util/Vector; HOTELID ADHERENTID TAUXGENEROSITE DATEDEBUT DATEFIN CSV_SEPARATOR CSV_NEWLINE csvFileName e Ljava/lang/Exception; sqlQuery Ljava/lang/StringBuilder; dt Ljava/util/Date; c Ljava/util/Calendar; exportDate flds [Ljava/lang/String; bw Ljava/io/BufferedWriter; sb Ljava/lang/StringBuffer; i I row Ljava/util/Hashtable; hotelID adherentID tauxGenerosite StackMapTable java/lang/Throwable uploadTauxGenFileToCev 4(Lcom/edeal/frontline/FlContext;Ljava/lang/String;)V$ TAUX.GENEROSITE.CEV.HOSTNAME& @Erreur lors de la récupération de TAUX.GENEROSITE.CEV.HOSTNAME @( C) *(Ljava/lang/Object;Ljava/lang/Throwable;)V+ localhost- TAUX.GENEROSITE.CEV.PORT /10 java/lang/Integer23 parseInt (Ljava/lang/String;)I5 <Erreur lors de la récupération de TAUX.GENEROSITE.CEV.PORT7 TAUX.GENEROSITE.CEV.FTPUSER9 ?Erreur lors de la récupération de TAUX.GENEROSITE.CEV.FTPUSER; ftpuser= TAUX.GENEROSITE.CEV.FTPPWD? >Erreur lors de la récupération de TAUX.GENEROSITE.CEV.FTPPWDA (preparing the host information for sftp.C com/jcraft/jsch/JSch B BFGH getSession @(Ljava/lang/String;Ljava/lang/String;I)Lcom/jcraft/jsch/Session; JLK com/jcraft/jsch/SessionM O setPasswordO java/util/Properties N R StrictHostKeyCheckingT no NVWX put 8(Ljava/lang/Object;Ljava/lang/Object;)Ljava/lang/Object; JZ[\ setConfig (Ljava/util/Properties;)V J^_ connecta Host connected.c sftp Jefg openChannel -(Ljava/lang/String;)Lcom/jcraft/jsch/Channel; i^j com/jcraft/jsch/Channell "sftp channel opened and connected.n com/jcraft/jsch/ChannelSftp Xpq substring msWt '(Ljava/lang/String;Ljava/lang/String;)Vv %File transfered successfully to host.x +Exception found while tranfer the response. z|{ java/lang/System} gc Erreur lors de System.gc();? java/io/File ? N ???? delete ()Z? -Erreur lors de (new File(filename)).delete(); m?? exit? %Erreur lors de channelSftp.exit(); ? sftp Channel exited. i?? disconnect? $Erreur lors de channel.disconnect();? Channel disconnected. J?? $Erreur lors de session.disconnect();? Host Session disconnected. filename server port user pass session Lcom/jcraft/jsch/Session; channel Lcom/jcraft/jsch/Channel; channelSftp Lcom/jcraft/jsch/ChannelSftp; jsch Lcom/jcraft/jsch/JSch; config Ljava/util/Properties; src dst ex SourceFile /TauxGenerositeToCevTransmissionTask_Helper.java ! ) ¸ ³ ± / *· ± ( º» Y· "M#N%:':):+:-:/: : *1¶ 3: § V:² ¶ 9¹ ? E: G» IYK· M» PY· R¶ S¶ W: § @: G» IYK· M» PY· R¶ S¶ W: ¿ G» IYK· M» PY· R¶ S¶ W: » ]Y· _:`¶ bWf¶ bWh¶ bWj¶ bWl¶ bWn¶ bWp¶ bWr¶ bWt¶ bWv¶ bWx¶ bWz¶ bW|¶ bW~¶ bW+Æ ®+¶ ?? §+¶ ?¶ ?N ?» PY· R:¸ ?: ¶ ? ¶ ?» ]Y ¶ ?`¸ ?· ¡¶ ¢:» ]Y ¶ ?¸ ?· ¡¶ ¢::*¥¶ 3:§ :² ¶ 9¹ ? §:©¶ W«¶ W:» ]Y· ¡¶ b¯¶ b¶ ¢¶ bW±¶ bW² » ]Y³· ¡¶ µ¶ ¢¹ ¸ ½ XY#SY%SY'SY)SY+S:*¶ ¢¸ »M,Æ¢,¶ Á??: » ÄY» ÆY» ÈY · ÊË· Í· Ð: » ÓY· Õ:Ö¶ ØWÛ¶ ØWݶ ØW߶ ØWᶠØW ¶ ã¶ ä ¶ ç6§ ç,¶ êÀ î:#¶ ðÀ X:%¶ ðÀ X:'¶ ðÀ X:)¶ ðÀ X:+¶ ðÀ X:» ÓY· Õ:» ]Y¸ ó· ¡-¶ b¶ ¢¶ ØW» ]Y¸ ó· ¡-¶ b¶ ¢¶ ØW» ]Y¸ ó· ¡-¶ b¶ ¢¶ ØW» ]Y¸ ó· ¡-¶ b¶ ¢¶ ØW» ]Y¸ ó· ¡/¶ b¶ ¢¶ ØW ¶ ã¶ ä ¶ ç?,¶ Á¡ÿ§ 8:² ¶ 9¹ ? Æ 3 ¶ ö§ +:§ &: Æ ¶ ö§ :¿ Æ ¶ ö§ : ° &