Witness Ranking Page Update: View Your Votes

in #witness-category4 years ago (edited)

Now you'll be able to view your votes in the witness ranking page. For example:

https://steemyy.com/witness-ranking/?id=justyy

image.png

This is made possible by the steem-js at the client. Thus, the votes are obtained from your browser, after the DOM of the page finished loading.

Steem Js code:

steem.api.getAccounts(["justyy"], function(err, result) {
  if (!err) {
    var proxy = result[0].proxy;
    var votes = result[0].witness_votes;
    if (proxy !== "") {
        $("div#votes").html(link(result[0].name) + " sets " + link(proxy) + " as witness voting proxy.");
    } else {
        var msg = "<B>" + link(result[0].name) + "</B> has voted <B>" + votes.length + "</B> <span style='background-color:yellow'>witnesses</span>, <B>" + (30 - votes.length) + "</B> slots left.";
        $("div#votes").html(msg); 
        for (var v of votes) {
            $("tr#" + v).children('td, th').css("background-color","yellow");
        }
    }
  } else {  
    $("div#votes").html("<font color=red>" + JSON.stringify(err) + "</font>");  
  }
});

If you set a proxy, of course, you will see something different.

image.png

Yes, I know. I am a terrible UI design, and choosing colours is not my thing. Let me know the options!

This tool is also available in Chinese: https://steemyy.com/witness-ranking-table/?id=justyy


I hope this helps!

Steem On!~


If you like my work, please consider voting for me, thanks!
https://steemit.com/~witnesses type in justyy and click VOTE



Alternatively, you could proxy to me if you are too lazy to vote!

Also: you can vote me at the tool I made: https://steemyy.com/witness-voting/?witness=justyy

Visit me at: https://steemyy.com

Sort:  

Dear mister @justyy. Thank you for sharing these tools for witnesses! It is kindly appreciated. I hope we can meet each other and have a wonderful future. Can you please read my witness statement and give your thoughts. Hope to speak you soon! KR Ciska [STEEM WITNESS]

Hi~ justyy!
@annepink has gifted you 1 SHOP!

Currently you have: 13 SHOP

View or Exchange SHOP Please go to steem-engine.com.

Are you bored? Play Rock,Paper,Scissors game with me!

你好鸭,justyy!

@cloudblade给您叫了一份外卖!

春天到了~

吃饱了吗?跟我猜拳吧! 石头,剪刀,布~

如果您对我的服务满意,请不要吝啬您的点赞~

Coin Marketplace

STEEM 0.23
TRX 0.12
JST 0.029
BTC 66195.81
ETH 3505.33
USDT 1.00
SBD 3.18