Package com.structis.fichesst.server.bean.domain

Examples of com.structis.fichesst.server.bean.domain.FicheSt


  }
 
  private String createGridReport(List<FicheSt> grid,List<String> listSrcGrid,List<String> listSrcTotalGroupGrid){
   
    List<String> lstKeyGrid = createKeyGrid1(grid);
    FicheSt ficheSt = null
    double sumtotalObjectif = 0.0;
    double sumtotalObj = 0.0;
    double sumtotalTransfert = 0.0;
    double sumtotalRd = 0.0;
    double sumtotalTs = 0.0;
    double sumtotaltotal =0.0;
    double sumtotalTraite = 0.0;
    double sumtotalArrete = 0.0;
    double sumtotalNonArete = 0.0;
    double sumtotalProvision = 0.0;
    double sumtotalTotalFinal = 0.0;
    double sumtotalDevisRefuse =0.0;
    double sumtotalEcartM = 0.0;
    double sumtotalEcratM1 = 0.0;
    double sumtotalVariationM = 0.0;
    double sumtotalEcartDernierPoint = 0.0;
    double sumtotalVariationEcartPoint = 0.0;
    double sumtotalAvctBA = 0.0;
    double summontantBA = 0.0;
    double sumtotalAvctReel = 0.0;
    double summontantReel = 0.0;
    double sumtotalCanto = 0.0;
    double sumtotalBadge = 0.0;
    double sumtotalGrue = 0.0;
    double sumtotlaLift = 0.0;
    double sumtotalBenne = 0.0;
    double sumtotalNettoy = 0.0;
    double sumtotalAutres = 0.0;
    double sumtotalProrata = 0.0;
    double sumtotalTotal = 0.0;
    double sumtotalPrestationTraite = 0.0;
    double sumtotalPenaliteFacture = 0.0;
    double sumtotalProrataAppliqueSt = 0.0;
    double sumtotalProrataMarche = 0.0;
    double sumtotalProrataSuRad = 0.0;
    double sumtotalMarcheRestantATraiterPercentage = 0.0;
    double sumtotalMarcheRestantATraiter = 0.0;
    double sumtotalVariationDuAuxTransferts = 0.0;
    double sumtotalManqueAGagnerStsansProrata = 0.0;
   
    double cellts = 0.0;
    double celltotlafinal = 0.0;
   
    java.text.NumberFormat numberFormat = NumberFormat.getInstance(Locale.FRENCH);
    numberFormat.setMaximumFractionDigits(1)
    for(int i=0;i< lstKeyGrid.size();i++){
      String grid1 = "";
      String sumTotalGroup1 = "";
      double totalObjectif = 0.0;
      double totalObj = 0.0;
      double totalTransfert = 0.0;
      double totalRd = 0.0;
      double totalTs = 0.0;
      double totaltotal =0.0;
      double totalTraite = 0.0;
      double totalArrete = 0.0;
      double totalNonArete = 0.0;
      double totalProvision = 0.0;
      double totalTotalFinal = 0.0;
      double totalDevisRefuse =0.0;
      double totalEcartM = 0.0;
      double totalEcratM1 = 0.0;
      double totalVariationM = 0.0;
      double totalEcartDernierPoint = 0.0;
      double totalVariationEcartPoint = 0.0;
      double totalAvctBA = 0.0;
      double montantBA = 0.0;
      double totalAvctReel = 0.0;
      double montantReel = 0.0;
      double totalCanto = 0.0;
      double totalBadge = 0.0;
      double totalGrue = 0.0;
      double totlaLift = 0.0;
      double totalBenne = 0.0;
      double totalNettoy = 0.0;
      double totalAutres = 0.0;
      double totalProrata = 0.0;
      double totalTotal = 0.0;
      double totalPrestationTraite = 0.0;
      double totalPenaliteFacture = 0.0;
      double totalProrataAppliqueSt = 0.0;
      double totalProrataMarche = 0.0;
      double totalProrataSuRad = 0.0;
      double totalMarcheRestantATraiterPercentage = 0.0;
      double totalMarcheRestantATraiter = 0.0;
      double totalVariationDuAuxTransferts = 0.0;
      double totalManqueAGagnerStsansProrata = 0.0;
      for(int j=0;j<grid.size();j++){
        ficheSt = grid.get(j);
        if(lstKeyGrid.get(i).equalsIgnoreCase(ficheSt.getLotType().getName())){
          cellts = ficheSt.getObj() + ficheSt.getTransferts() + ficheSt.getRd() + ficheSt.getTs();
          celltotlafinal = ficheSt.getTraite() + ficheSt.getArrete() + ficheSt.getNonArrete() + ficheSt.getProvision();
          totalObjectif += ficheSt.getObjectif();
          totalObj += ficheSt.getObj();
          totalTransfert += ficheSt.getTransferts();
          totalRd += ficheSt.getRd();
          totalTs += ficheSt.getTs();
          totaltotal += cellts;
          totalTraite += ficheSt.getTraite();
          totalArrete += ficheSt.getArrete();
          totalNonArete += ficheSt.getNonArrete();
          totalProvision += ficheSt.getProvision();
          totalTotalFinal += celltotlafinal;
          totalDevisRefuse +=ficheSt.getDevisRefuse();
          totalEcartM += getEcardM(ficheSt);
          totalEcratM1 += ficheSt.getEcartM1();
          totalVariationM += getVariationM(ficheSt);
          totalEcartDernierPoint += ficheSt.getEcartDernierPoint();
          totalVariationEcartPoint += getVariationEcartPointM(ficheSt);
          totalAvctBA += getAvctBAPercentage(ficheSt);
          montantBA += ficheSt.getTotalCumule();
 
          totalAvctReel += getAvctReelPercentage(ficheSt);
          montantReel += ficheSt.getTraite();
          totalCanto += ficheSt.getTotalCanto();
          totalBadge += ficheSt.getTotalBadge();
          totalGrue += ficheSt.getTotalGrue();
          totlaLift += ficheSt.getTotalLift();
          totalBenne += ficheSt.getTotalBenne();
          totalNettoy += ficheSt.getTotalNettoy();
          totalAutres += ficheSt.getTotalAutres();
          totalProrata += ficheSt.getTotalProrata();
          totalTotal += getTotal2(ficheSt);
          totalPrestationTraite += getPrestationTraitePercentage(ficheSt);
          totalPenaliteFacture += ficheSt.getTotalPenalty();
          totalProrataAppliqueSt += ficheSt.getPrestaProrata();
          totalProrataMarche += getProrataMarche(ficheSt);
          totalProrataSuRad += getProrataSurRAD(ficheSt);
          totalMarcheRestantATraiterPercentage += getMarchesRestantATraiterPercentage(ficheSt);
          totalMarcheRestantATraiter += getMarchesRestantATraiter(ficheSt);
          totalVariationDuAuxTransferts += getVariationDuAuxTransferts(ficheSt);
View Full Code Here


    List<FicheSt> listFicheSt = new ArrayList<FicheSt>();
   
    String fichestIds = request.getParameter("fichestIds");
    String hasGestion = request.getParameter("isHasGestion");
    if(fichestIds != null && fichestIds.length() > 0){
      FicheSt ficheSt = null;
      List<CautionFournie> listCautionFournie = null;
      fichestIds = fichestIds.substring(0,fichestIds.length() - Constants.SEPRATE.length());
      String [] arr = fichestIds.split(Constants.SEPRATE);
      for(int i=0;i<arr.length;i++){
        ficheSt = ficheStService.find(new Integer(arr[i]));
        listCautionFournie = cautionFournieService.findByFicheStId(ficheSt.getId());
        ficheSt.setCautionFournies(listCautionFournie);
        listFicheSt.add(ficheSt);
      }
    }
    try {
      //response.setContentType("application/pdf" );
View Full Code Here

  @Override
  @Transactional
  public FicheSt update(FicheSt ficheSt) throws DataConstraintException, Exception {
    if( ficheSt != null ) {
      FicheSt persistence = find(ficheSt.getId());
     
      if (persistence != null) {
        List<CautionFournie> cautionFournieList = persistence.getCautionFournies();
        if (cautionFournieList != null) {
          for (Iterator<CautionFournie> iterator = cautionFournieList.iterator(); iterator.hasNext();) {
            CautionFournie cautionFournie = (CautionFournie) iterator.next();
            cautionFournie.setFicheSt(null);
            iterator.remove();
          }
        }

        List<Gestion> gestionList = persistence.getGestions();
        if (gestionList != null) {
          for (Iterator<Gestion> iterator = gestionList.iterator(); iterator.hasNext();) {
            Gestion gestion = iterator.next();
            gestion.setFicheSt(null);
            iterator.remove();
          }
        }

        List<Deduction> deductionList = persistence.getDeductions();
        if (deductionList != null) {
          for (Iterator<Deduction> iterator = deductionList.iterator(); iterator.hasNext();) {
            Deduction deduction = iterator.next();
            deduction.setFicheSt(null);
            iterator.remove();
          }
        }

        List<Progress> progressList = persistence.getProgresses();
        if (progressList != null) {
          for (Iterator<Progress> iterator = progressList.iterator(); iterator.hasNext();) {
            Progress progress = iterator.next();
            progress.setFicheSt(null);
            iterator.remove();
          }
        }

        List<Penalty> penaltyList = persistence.getPenalties();
        if (penaltyList != null) {
          for (Iterator<Penalty> iterator = penaltyList.iterator(); iterator.hasNext();) {
            Penalty penalty = iterator.next();
            penalty.setFicheSt(null);
            iterator.remove();
View Full Code Here

    return results;
    }
 
  @Override
  public FicheSt find(Integer id) {
    FicheSt result = ficheStDao.find(id);
    if(result != null) {
      result.calculateValues();
    }
   
    return result;
  }
View Full Code Here

  public FicheStDto find(Integer id) {
    ManagerCallBack manager = new ManagerCallBack() {
      @Override
      public Object execute(Object... inputs) throws Exception {
        try {
          FicheSt ficheSt = ficheStService.find((Integer) inputs[0]);
          return ficheSt;
        }
        catch( Exception e ) {
          throw e;
        }
View Full Code Here

    contentNormalGrayFont.setSize(8.5f);
  }
 
  @Override
  public void render() throws DocumentException {
    FicheSt ficheSt = null;
    for(int i=0;i<listFicheSt.size();i++){
      ficheSt = listFicheSt.get(i);
      String generaleInformation = createGeneralInformation(ficheSt);
      String conditionsparticulieres = createCondition(ficheSt);
      String prestations = createPresation(ficheSt);
      String informationscomplementaires = createInformationComplementaires(ficheSt);
      String cautionFournies = createCautionGrid(ficheSt.getCautionFournies());

      //Parameters for gestional report
      List<String> listSrcGestion = new ArrayList<String>();
      List<String> listSumGroupGestion = new ArrayList<String>();
      String alltotalgestion = createGestion(ficheSt.getGestions(), listSrcGestion, listSumGroupGestion)
      String summary = createGestionSummary(ficheSt.getGestions());
      String budget = createBudget(ficheSt);
     
      //Parameters for report process
      List<String> listSrcProcess = new ArrayList<String>();
      String sumProcesses = createProgress(ficheSt.getProgresses(), listSrcProcess);
      String grid2_report = createDetailDesRetenuesAppliquies(ficheSt.getGestions(), ficheSt.getDeductions(), ficheSt.getPenalties(),ficheSt);
      String grid3_report = createProgessGrird3Report(ficheSt);
     
      //Deducation
      String chantierNom = ficheSt.getConductor() != null ? ficheSt.getConductor().getChantier().getNom() : "";
      String conductorSiTravaux = ficheSt.getConductor() != null ? ficheSt.getConductor().getIdSiTravaux() : "";
      String information = chantierNom + Constants.SEPRATE + conductorSiTravaux + Constants.SEPRATE + ficheSt.getSociete();
      String[] arrDeduction = createDeductionGrid(ficheSt);
      String[] arrPenalty = createPenalite(ficheSt.getPenalties());
     
      this.generaleInformation = generaleInformation;
      this.conditionsparticulieres = conditionsparticulieres;
      this.prestations = prestations;
      this.informationscomplementaires = informationscomplementaires;
      this.cautionFournies = cautionFournies;
      this.gestions = listSrcGestion;
      this.totalgestions = listSumGroupGestion;
      this.alltotalgestion = alltotalgestion;
      this.summary = summary;
      this.budget = budget;
     
      this.processes = listSrcProcess.get(0);
      this.totalsituation = sumProcesses;
      this.grid2 = grid2_report;
      this.grid3 = grid3_report;
      this.etatAvancement = calculateEtatAvancement(ficheSt.getGestions(),ficheSt.getProgresses());
     
      this.information = information;
      this.deductions = arrDeduction[0];
      this.totaldeduction = arrDeduction[1];
      this.penaltys = arrPenalty[0];
      this.amount = arrPenalty[1];
      this.commentaire = ficheSt.getAcptCommentaires();
      this.internalCommentaire = ficheSt.getAcptCommentairesInternes();
     
     
      addAllFichestDto();
    }   
  }
View Full Code Here

TOP

Related Classes of com.structis.fichesst.server.bean.domain.FicheSt

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.