<div class="row-fluid">
	<div class="span1 hidden-phone"></div>
	<div class="span10">
		<table class="table table-bordered table-condensed table-hover table-striped">
			<thead>
				<tr>
					<th>${_('Username')}</th>
					<th>${_('Status')}</th>
					<th>${_('Errors')}</th>
				</tr>
			</thead>
			<tbody>
				% if c.finished:
					% if c.results and 'rows' in c.results:
						% for result in c.results['rows']:
						<tr>
							<td>${h.link_to(result['username'], url('account-detail', userid=result['id'])) if result['id'] else result['username']}</td>
							<td>
								${functions.item_status(result['imported'])}
							</td>
							<td class="eimportstatus">
								${h.wrap_paragraphs(result['error'], 50) if result['error'] else 'None'}
							</td>
						</tr>
						% endfor
					% else:
						<tr>
							<td colspan="3">
							${_('The CSV import failed: %s') % c.results['global_error']}
							</td>
						</tr>
					% endif
				% else:
				<tr>
					<td colspan="3">
						<%
						count = session['acimport-count']
						if count > 10:
							count = 10
						percent = h.percent_of(count, 10)
						%>
						${h.portable_img('imgs/ajax-pager.gif', alt="")} 
						${_('The request is being processed. %d%%' % percent)} 
						<div class="progress" data-percent="${"%d%%" % percent}">
							<div class="bar" style="width: ${"%d%%" % percent};"></div>
						</div>
					</td>
				</tr>
				% endif
			</tbody>
		</table>
	</div>
	<div class="span1 hidden-phone"></div>
</div>



<%def name="headers()">\
% if not c.finished:
<meta http-equiv="refresh" content="5" />
% endif
</%def>
<%def name="title()">\
${_('Accounts :: User import status')}
</%def>
<%def name="heading()">\
${_('Accounts :: User import status')}
</%def>
<%def name="submenu()"></%def>
<%def name="localscripts()">\
</%def>
<%namespace name="functions" file="../includes/functions.html"/>
<%inherit file="../base.html"/>
