show trust status of certificate issuers in cli as well

pull/24/head
Zlatin Balevsky 2019-11-06 18:19:45 +00:00
parent b3f775f59a
commit 5802ba7734
2 changed files with 4 additions and 3 deletions

View File

@ -17,7 +17,7 @@ class ViewCertificatesModel {
private final Core core
private final TextGUIThread guiThread
private final TableModel model = new TableModel("Issuer","File Name","Comment","Timestamp")
private final TableModel model = new TableModel("Issuer","Trust Status","File Name","Comment","Timestamp")
private int totalCerts
@ -52,7 +52,8 @@ class ViewCertificatesModel {
void onCertificateFetchedEvent(CertificateFetchedEvent e) {
guiThread.invokeLater {
Date date = new Date(e.certificate.timestamp)
model.addRow(new CertificateWrapper(e.certificate), e.certificate.name.name, e.certificate.comment != null, date)
model.addRow(new CertificateWrapper(e.certificate), core.trustService.getLevel(e.certificate.issuer.destination),
e.certificate.name.name, e.certificate.comment != null, date)
String percentageString = ""
if (totalCerts > 0) {

View File

@ -49,7 +49,7 @@ class ViewCertificatesView extends BasicWindow {
topPanel.addComponent(percentageLabel, layoutData)
contentPanel.addComponent(topPanel, layoutData)
table = new Table("Issuer","File Name","Comment","Timestamp")
table = new Table("Issuer","Trust Status","File Name","Comment","Timestamp")
table.with {
setCellSelection(false)
setTableModel(model.model)