Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

191
Visualizações
Javascript to export html table to Excel with change in column's having timeStamp to human readable Date and time

My problem is that in my database all date column is stored in timestamp so during displaying data on the table we convert this into human-readable .So I want to do the same thing during export.

Below picture is my export data

the red colour portion is timestamp value which is stored in a database so during export I want this as human-readable date and time.

This is my code

      export const onExport = (exportParams) => {
      let endpoint = exportParams.endpoint;
      if(store.state.project && store.state.project.id){
      endpoint += "&projectId=" + store.state.project.id;
    }
    window.location =
        store.state.api.url.replace("/v2.1", "") +
        "/grid/data/export?endpoint=" +
        encodeURIComponent(endpoint) +
        "&columns=" +
        encodeURIComponent(JSON.stringify(exportParams.columns)) +
        "&export-format=" +
        exportParams["export-format"] +
        "&name=" +
        exportParams.name +
        "&token=" +
        store.state.api.token;
      store.state.project.id : '';
      }; 

I go through several questions on StackOverflow but I did not find any solution

I visited. Javascript to export html table to Excel but I did not get my answer

In the database this column is stored as timestamp

The above picture is of stored value in the database.

So my goal is to get this column as human-readable in the export results. Thanks!

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda