<div class="bill-stub">
	<div class="row">
		<div class="col-xs-8">
			<div class="title">
				<a href="{{ url_for('bill', bill_id=result.id) }}">{{ result.title }}</a>
			</div>
		</div>
		<div class="col-xs-2">
			{% if result.status %}
				{% if status_dict[result.status.name] %}
				<span class="label {{ status_dict[result.status.name][1] }}">{{ status_dict[result.status.name][0] }}</span>
				{% else %}
				<span class="label label-default">{{ result.status.name }}</span>
				{% endif %}
			{% endif %}
		</div>
		<div class="col-xs-2">
			[{{ result.code }}]
		</div>
	</div>
</div>

{% if result._source %}
	{% if result.highlight.title %}
		{% set title = result.highlight.title[0]|search_snippet %}
	{% else %}	
		{% set title = result._source.title %}
	{% endif %}
	{% set date = result._source.date %}
	{% set id = result._id %}
{% else %}
	{% set title = result.title %}
	{% set date = result.date %}
	{% set id = result.id %}
{% endif %}

<div class="bill-stub">
	<div class="row">
		<div class="col-xs-8">
			<div class="title">
				<a href="/bill/{{ id }}">{{ title }}</a>
			</div>
		</div>
		<div class="col-xs-2">
			{% if result.status %}
				{% if status_dict[result.status.name] %}
				<span class="label {{ status_dict[result.status.name][1] }}">{{ status_dict[result.status.name][0] }}</span>
				{% else %}
				<span class="label label-default">{{ result.status.name }}</span>
				{% endif %}
			{% endif %}
		</div>
		<div class="col-xs-2">
			{% if result.code %}
			[{{ result.code }}]
			{% endif %}
		</div>
	</div>
</div>

Fix error on search results for bills.
Fix error on search results for bills.
