My Steemit Friends Update: Fixed Contribution Ranking Feature, Added Contribution Calculator

in #utopian-io7 years ago (edited)

Tool website: http://mysteemitfriends.online
Github: https://github.com/Bulletproofmonk/MySteemitFriends
Merged pull request: https://github.com/Bulletproofmonk/MySteemitFriends/pull/2

Bug Fixes

  • Issue: The Contribution ranking feature on My Steemit Friends was not working, because it was using the steemJS interactive API which is currently not working.

image.png

This is the error message that showed up.

image.png

  • Solution: I re-coded the whole feature to obtain the data using a different method.
    Old Method: Using PHP cURL in getdollars.php to connect to the interactive API at https://api.steemjs.com. This file has been deleted because it is no longer needed.
    New Method: I connect to the new Steem API node at https://api.steemit.com directly using SteemJS and Javascript, bypassing the interactive API, in upvotelist.php.

New Features

  • Show, Hide ranking list buttons.
  • Calculator to add up contributions.
  • Added voting percentage and table formatting in contribution ranking.
    To test out these new features, please follow the instructions below.

Please go to http://mysteemitfriends.online. Enter your username, then click on "Upvote Stats".

image.png

Then click on the number of articles upvoted by a specific user to get to the upvotelist.php page.

image.png

Once you are on this page, click on the new button "Show Contribution Ranking & Add to Calculator".

image.png

After you click Show Contribution ranking, you will see the following screen.

image.png

As you click on more ""Show Contribution Ranking & Add to Calculator" buttons for more articles, you can see that the Calculator at the top of the screen calculates how much the voter has contributed towards your articles.

image.png

You can also click on the white Show Full Ranking List button which will show you how much everyone has contributed as well as their voting percentage towards your article.

image.png

  • How did you implement it/them?
    As shown in the file upvotelist.php, When the "Show Contribution Ranking & Add to Calculator" is clicked, I use SteemJS to retrieve the data on the total payout value of each article as well as how much each voter has contributed towards your article in rshares. I then divide the rshares of each voter by the total rshares of this article to get the percentage of contribution by each user, and then multiply the percentage by the total payout value to get each user's payout contribution. I then add the voter's payout contribution to the calculator at the top and display the full ranking list on the page using a table.

Github Signed in session:
image.png



Posted on Utopian.io - Rewarding Open Source Contributors

Sort:  

Thank you for the contribution. It has been approved.

Please try to increase the quality of your contributions in future and let's see what features you add to it in the future.

Suggestion - Try to improve the UI also a bit.

You can contact us on Discord.
[utopian-moderator]

Hey @ms10398, I just gave you a tip for your hard work on moderation. Upvote this comment to support the utopian moderators and increase your future rewards!

Very well deserved tip!!

Thanks for the valuable suggestion @ms10398

Hey @magicmonk I am @utopian-io. I have just upvoted you!

Achievements

  • Seems like you contribute quite often. AMAZING!

Community-Driven Witness!

I am the first and only Steem Community-Driven Witness. Participate on Discord. Lets GROW TOGETHER!

mooncryption-utopian-witness-gif

Up-vote this comment to grow my power and help Open Source contributions like this one. Want to chat? Join me on Discord https://discord.gg/Pc8HG9x

thank you so much :)

That calculator is a really neat new function

Thank you so much for your continued support :)

Great work my Eddie! Love your app and use it all the time!

this is a really cool thing @magicmonk . I had no idea something like this could exist. Its going to be really interesting to use this as I continue to grow on steemit.

Thanks buddy. Glad it helps.

Congratulation on doing an awesome job! cheers @magicmonk

thanks @alexandraioana26 !! You are doing a great job too! Gaining heaps of followers!

thnk u for sharing this valuable information with

interesting your post..
thanks for sharing.

Coin Marketplace

STEEM 0.16
TRX 0.13
JST 0.027
BTC 58994.66
ETH 2596.74
USDT 1.00
SBD 2.43