diff --git a/dist/Programa Caja.jar b/dist/Programa Caja.jar index 76c3bee..c434697 100644 Binary files a/dist/Programa Caja.jar and b/dist/Programa Caja.jar differ diff --git a/src/danielcortes/xyz/informes/InformeLibroDeVentasToExcel.java b/src/danielcortes/xyz/informes/InformeLibroDeVentasToExcel.java index d105db6..3275bce 100644 --- a/src/danielcortes/xyz/informes/InformeLibroDeVentasToExcel.java +++ b/src/danielcortes/xyz/informes/InformeLibroDeVentasToExcel.java @@ -45,7 +45,7 @@ public class InformeLibroDeVentasToExcel { "TOTAL", "INICIAL", "FINAL", "VALOR", "INICIAL", "FINAL", "VALOR", - "TOTAL", "ACUMULADO", "" + "TOTAL", "ACUMULADO", "PROMEDIO BOLETAS" }; private final String[] dias = {"Lunes", "Martes", "Miercoles", "Jueves", "Viernes", @@ -154,11 +154,15 @@ public class InformeLibroDeVentasToExcel { ); if (rowCounter == 2) { - dataRow.createCell(cellCounter).setCellFormula(("U" + (rowCounter + 1))); + dataRow.createCell(cellCounter++).setCellFormula(("U" + (rowCounter + 1))); } else { - dataRow.createCell(cellCounter) + dataRow.createCell(cellCounter++) .setCellFormula(("U" + (rowCounter + 1)) + ("+") + ("V" + (rowCounter))); } + + dataRow.createCell(cellCounter).setCellFormula( + String.format("J%s/(I%s-H%s)", rowCounter + 1, rowCounter + 1, rowCounter + 1) + ); rowCounter++; currentDate = currentDate.plusDays(1); } @@ -273,6 +277,7 @@ public class InformeLibroDeVentasToExcel { //Estadisticas row.getCell(y++).setCellStyle(this.styles.get("money")); + row.getCell(y++).setCellStyle(this.styles.get("money")); row.getCell(y).setCellStyle(this.styles.get("money")); }