Skip to content

Commit

Permalink
example usage of a property
Browse files Browse the repository at this point in the history
  • Loading branch information
tobes committed Jun 1, 2012
1 parent 5caf21d commit 9d38187
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion ckan/controllers/home.py
Expand Up @@ -46,7 +46,11 @@ def index(self):
'fq': 'capacity:"public"'
}
query = ckan.logic.get_action('package_search')(context,data_dict)
c.package_count = query['count']
#c.package_count = query['count']
@property
def package_count():
return query['count']
c.package_count = package_count
c.facets = query['facets']

data_dict = {'order_by': 'packages', 'all_fields': 1}
Expand Down

0 comments on commit 9d38187

Please sign in to comment.