<commit_before><ul class="breadcrumb">
  <li>
    <a href='{url url="/quiz/index/$collection_id"}'>Quizzes</a> <span class="divider">/</span>
  </li>
  <li class="active">Questions</li>
</ul>

<div>
	<h1>Questions</h1>
</div>

<div id="questions-container">
	<a class="btn" href='{url url="/question/create/$quiz_id"}'>New Question</a>
{if $sizeofquestions > 0}
	<table id="questions-table" class="table table-condensed">
		<thead>
			<tr>
				<th></th>
				<th>Question</th><th>Actions</th>
			</tr>
		</thead>
		<tbody>
{foreach from=$questions item=question name=qounter}

		<tr data-position="{$smarty.foreach.qounter.index + 1}" id="{$question['ID']}" class="question-row-{$question['ID']}">
			<td>{$smarty.foreach.qounter.index + 1}</td>
			<td><a href="{url url='/question/view/'|cat:$question['ID']}">{$question['TITLE']}</a></td>
			<td>
				<a href="{url url='/question/create/'|cat:$quiz_id|cat:'/'|cat:$question['ID']}">Edit</a><br/>

				<a class="question-delete-btn" name="#question-delete-modal-{$question['ID']}" >Delete</a>
				<div class="modal hide" id="question-delete-modal-{$question['ID']}">
				  <div class="modal-header">
				    <button type="button" class="close" data-dismiss="modal">×</button>
				    <h3>Delete Question</h3>
				  </div>
				  <div class="modal-body">
				    <p>Are you sure you want to delete this Question?</p>
				  </div>
				  <div class="modal-footer">
				    <a href="#" class="btn btn-primary question-delete-action" name="{$question['ID']}" data-dismiss="modal">Delete</a>
				    <a href="#" class="btn" data-dismiss="modal">Cancel</a>
				  </div>
				</div>
				
			</td>
		</tr><commit_msg>closes #117: question title now links to edit view<commit_after><ul class="breadcrumb">
  <li>
    <a href='{url url="/quiz/index/$collection_id"}'>Quizzes</a> <span class="divider">/</span>
  </li>
  <li class="active">Questions</li>
</ul>

<div>
	<h1>Questions</h1>
</div>

<div id="questions-container">
	<a class="btn" href='{url url="/question/create/$quiz_id"}'>New Question</a>
{if $sizeofquestions > 0}
	<table id="questions-table" class="table table-condensed">
		<thead>
			<tr>
				<th></th>
				<th>Question</th><th>Actions</th>
			</tr>
		</thead>
		<tbody>
{foreach from=$questions item=question name=qounter}

		<tr data-position="{$smarty.foreach.qounter.index + 1}" id="{$question['ID']}" class="question-row-{$question['ID']}">
			<td>{$smarty.foreach.qounter.index + 1}</td>
			<!-- <td><a href="{url url='/question/view/'|cat:$question['ID']}">{$question['TITLE']}</a></td> -->
			<td><a href="{url url='/question/create/'|cat:$quiz_id|cat:'/'|cat:$question['ID']}">{$question['TITLE']}</a></td>
			<td>
				<a href="{url url='/question/view/'|cat:$question['ID']}">View</a><br/>
				<a href="{url url='/question/create/'|cat:$quiz_id|cat:'/'|cat:$question['ID']}">Edit</a><br/>

				<a class="question-delete-btn" name="#question-delete-modal-{$question['ID']}" >Delete</a>
				<div class="modal hide" id="question-delete-modal-{$question['ID']}">
				  <div class="modal-header">
				    <button type="button" class="close" data-dismiss="modal">×</button>
				    <h3>Delete Question</h3>
				  </div>
				  <div class="modal-body">
				    <p>Are you sure you want to delete this Question?</p>
				  </div>
				  <div class="modal-footer">
				    <a href="#" class="btn btn-primary question-delete-action" name="{$question['ID']}" data-dismiss="modal">Delete</a>
				    <a href="#" class="btn" data-dismiss="modal">Cancel</a>
				  </div>
				</div>
				
			</td>
		</tr>
{'fraction_non_alphanumeric': 0.24774774774774774, 'fraction_numerical': 0.004786036036036036, 'mean_word_length': 4.156748911465892, 'pattern_counts': {'":': 0, '<': 135, '<?xml version=': 0, '>': 137, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5002277', 'n_tokens_mistral': 1504, 'n_tokens_neox': 1276, 'n_words': 213}