Converter arquivo CSV para Dashboard

I am new in this community, actually in this environment, and forgot that I should have written in English, so here it goes:

I need help to present data from a CSV file, UTT-8 (Comma-delimited) in a TAGO Dashboard. The file would be updated daily and deposited in Tago’s Files. Example below

Preciso de ajuda para apresentar dados provenientes de um arquivo CSV, UTT-8 (Comma-delimited) em um Dashboard. O arquivo seria atualizado diariamente e depositado, no Files da Tago.

Formato / Format
Date,Med 1,Med 2
08/11/21,12.00,12.00
09/11/21,12.00,12.00
10/11/21,12.00,12.00
11/11/21,12.00,12.00
12/11/21,12.00,12.00
13/11/21,12.00,12.00
14/11/21,12.00,12.00
15/11/21,12.00,12.00
16/11/21,12.00,12.00
17/11/21,12.00,12.00
18/11/21,12.00,12.00
19/11/21,12.00,12.00
20/11/21,12.00,12.00

Thanks
marianombr

1 Like

Hi @marianombr Welcome to our community!

Soon our team or users will reply to your question.

Regards!

Hi @marianombr,

Can you please elaborate here when you mentioned “dashboard”?

Did you mean you are looking for somehow display a CSV content into a table dynamic widget?

Dashboard is the whole page where will contain widgets. Widget are components such as dynamic table, display, dial, bar chart, map etc…

-Guilherme

Hi @guilhermeco,
Yes dynamic table would be perfect, with same
Columns as CSV file
Thanks

Mariano

1 Like

I see, thanks for the information.

The best ideia here is to have a form where you will be able to upload a spreadsheet. For example:

Notice that the button to submit the form triggers a script.

That script should follow this logic: (see this community post below)

Where you should:

  1. Fetch on the scope the url from the CSV file you’ve upload through the form
  2. Do a get request using axios through the url from point 1.
  3. Transform the CSV file into JSON. Using “csvtojson” (this is a recommendation, feel free yo use any CSV → JSON library).

This is the idea, please use these steps, read that other post from our community and it should help you through this.

Thanks,
Guilherme

1 Like

Thanks, appreciate.
Will try

BR3M

2 Likes