Commit 96a9b671 authored by Maxym Borodenko's avatar Maxym Borodenko
Browse files

MCPD Excel: Included LASTMODIFIED column

parent f1d2b495
......@@ -24,6 +24,8 @@ import java.lang.reflect.Method;
import java.net.URLEncoder;
import java.sql.ResultSet;
import java.sql.SQLException;
import java.text.Format;
import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.HashMap;
import java.util.List;
......@@ -136,6 +138,7 @@ public class DownloadServiceImpl implements DownloadService {
private static final int COL_HISTORIC = 39;
private static final int COL_ACCEURL = 40;
private static final int COL_REMARKS = 41;
private static final int COL_LASTMODIFIED = 42;
@Autowired
private AccessionProcessor accessionProcessor;
......@@ -370,6 +373,12 @@ public class DownloadServiceImpl implements DownloadService {
final String doi = accession.getDoi();
updateCell(row, COL_DOI, doi);
}
{
Format formatter = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
String lastModifiedDate = accession.getLastModifiedDate() != null ? formatter.format(accession.getLastModifiedDate()) : "";
updateCell(row, COL_LASTMODIFIED, lastModifiedDate);
}
}
@Override
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment