Skip to content

Commit

Permalink
Merge branch 'f744' into 'main'
Browse files Browse the repository at this point in the history
https://gitlab.com/pasosdeJesus/sivel2_gen/-/issues/744 arregla csv plotly

See merge request pasosdeJesus/sivel2_gen!531
  • Loading branch information
vtamara committed Jan 21, 2025
2 parents 94415fe + 1f6ed05 commit 45614f9
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 2 deletions.
3 changes: 1 addition & 2 deletions app/javascript/controllers/plotly_actos_controller.js
Original file line number Diff line number Diff line change
Expand Up @@ -254,8 +254,7 @@ export default class extends Controller {

plotly_serietiempo_actos() {
const self = this;
const ruta_relativa = window.location.pathname.split("/")[1]
Plotly.d3.csv("/" + ruta_relativa + "/" + ruta_relativa + "/csv/actos_individuales.csv", function(err, datos) {
Plotly.d3.csv("../assets/csv/actos_individuales.csv", function(err, datos) {
if (err) {
console.error("Error al cargar el archivo CSV:", err);
} else {
Expand Down
5 changes: 5 additions & 0 deletions test/dummy/app/javascript/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Heb412Gen__Motor.iniciar()
import Sivel2Gen__Motor from "./controllers/sivel2_gen/motor"
window.Sivel2Gen__Motor = Sivel2Gen__Motor
Sivel2Gen__Motor.iniciar()
import PlotlyActosController from "./controllers/sivel2_gen/plotly_actos_controller"


import TomSelect from 'tom-select';
Expand Down Expand Up @@ -89,6 +90,10 @@ promesaRecursosSprocketsYDocumento.then((mensaje) => {
p2ult = p[p.length - 2] + "/" + p[p.length - 1]
}

if (p2ult == 'graficar/actos_individuales') {
const plotlycontroller = new PlotlyActosController()
plotlycontroller.plotly_serietiempo_actos();
}
})


Expand Down

0 comments on commit 45614f9

Please sign in to comment.