Kaynağa Gözat

drk: show votes for a proposal

x 3 yıl önce
ebeveyn
işleme
d1a4405a95
1 değiştirilmiş dosya ile 7 ekleme ve 0 silme
  1. 7 0
      bin/drk/src/main.rs

+ 7 - 0
bin/drk/src/main.rs

@@ -1049,6 +1049,13 @@ async fn main() -> Result<()> {
 
                 println!("{}", proposal);
 
+                let votes = drk.get_dao_proposal_votes(proposal_id).await?;
+                println!("votes:");
+                for vote in votes {
+                    let option = if vote.vote_option { "yes" } else { "no " };
+                    println!("  {} {}", option, vote.all_vote_value);
+                }
+
                 Ok(())
             }