MySteemitFriends.Online new feature: Article count included in Contributors ranking, integration with Contribution calculator page.

in #utopian-io7 years ago (edited)

New Features

  • What feature(s) did you add?

The Contributors Ranking table on My Steemit Friends has a new feature - a new Article Count column, for you to see how many articles your contributors have voted on. Please test this feature out by going to http://mysteemitfriends.online/contributors.php, enter your username and click "Show Contributors. You will then see not only the amount contributed by each user towards your earnings, but also how many times they have voted you on the right hand side column.

image.png

If you click on any of the "article counts", you will also be taken to the "Contribution Calculator" built previously, where it will list all the articles which this user has voted on, as well as show you this voter's ranking in comparison with other voters for each of the articles.

image.png

You can also see an "Exclude Comments" checkbox is currently ticked by default (new feature added to contribution calculator). If you untick this checkbox and click "Calculate" again, you will see that comments will be included in the contribution calculator.

image.png

  • How did you implement it/them?

Relevant commit

contributors.php: New "article count" column in Contributor's ranking: I made another SQL query called "votecounting (on lines 205-219) which counts how many votes each voter has given the user. Then I joined the result from this table to the previous query result and added one more column to the select query. I also made the result from this query link to the contribution calculator using a combination of Javascript and PHP.

upvotelist.php: I added a checkbox to retrieve the parameter from the URL for whether comments are to be included, and then when the form is resubmitted I also make sure the checkbox value determines which query is submitted. I have also modified the original SQL query to bind variables to the prepared statement in order to reduce the likelihood of an SQL injection.



Posted on Utopian.io - Rewarding Open Source Contributors

Sort:  

Thank you for the contribution. It has been approved.

Good job, I can see as well that you took the time to refactor the code and take care of fixing the prepared statements.

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

thank you so much helo. You have helped me grow as a developer.

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

You're really taking it to a new level well done!

Thanks for adding this because that's the feature that i was talking about few days ago in your comments,thanks man great development

@magicmonk, I always try to support who contribute to open source project, upvote you.

Coin Marketplace

STEEM 0.19
TRX 0.18
JST 0.034
BTC 89118.52
ETH 3131.33
USDT 1.00
SBD 2.76