Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
  • Loading branch information
revflash committed Jul 5, 2016
2 parents 97e2436 + 7c4d8ca commit 0ea6049
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 2 deletions.
11 changes: 11 additions & 0 deletions libraries/app/database_api.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1331,6 +1331,17 @@ state database_api::get_state( string path )const
_state.content[key] = std::move(d);
}
}
else if( part[0] == "cashout" ) {
auto trending_disc = get_discussions_by_cashout( {tag,20} );

auto& didx = _state.discussion_idx[tag];
for( const auto& d : trending_disc ) {
auto key = d.author +"/" + d.permlink;
didx.cashout.push_back( key );
if( d.author.size() ) accounts.insert(d.author);
_state.content[key] = std::move(d);
}
}
else if( part[0] == "active" ) {
auto trending_disc = get_discussions_by_active( {tag,20} );

Expand Down
3 changes: 2 additions & 1 deletion libraries/app/include/steemit/app/state.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ namespace steemit { namespace app {
vector<string> updated; /// creation date
vector<string> active; /// last update or reply
vector<string> votes; /// last update or reply
vector<string> cashout; /// last update or reply
vector<string> maturing; /// about to be paid out
vector<string> best; /// total lifetime payout
vector<string> hot; /// total lifetime payout
Expand Down Expand Up @@ -166,7 +167,7 @@ FC_REFLECT_DERIVED( steemit::app::extended_account,
FC_REFLECT( steemit::app::vote_state, (voter)(weight)(rshares)(percent)(time) );
FC_REFLECT( steemit::app::account_vote, (authorperm)(weight)(rshares)(percent)(time) );

FC_REFLECT( steemit::app::discussion_index, (category)(trending)(updated)(created)(responses)(active)(votes)(maturing)(best)(hot) )
FC_REFLECT( steemit::app::discussion_index, (category)(trending)(updated)(created)(responses)(active)(votes)(maturing)(best)(hot)(cashout) )
FC_REFLECT( steemit::app::category_index, (trending)(active)(recent)(best) )
FC_REFLECT_DERIVED( steemit::app::discussion, (steemit::chain::comment_object), (url)(root_title)(pending_payout_value)(total_pending_payout_value)(active_votes)(replies) )

Expand Down
2 changes: 1 addition & 1 deletion libraries/chain/include/steemit/chain/config.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
*/
#pragma once

#define STEEMIT_BLOCKCHAIN_VERSION ( version(0, 8, 4) )
#define STEEMIT_BLOCKCHAIN_VERSION ( version(0, 8, 5) )
#define STEEMIT_BLOCKCHAIN_HARDFORK_VERSION ( hardfork_version( STEEMIT_BLOCKCHAIN_VERSION ) )

#ifdef IS_TEST_NET
Expand Down

0 comments on commit 0ea6049

Please sign in to comment.