forked from janek/compareware
		
	adjusted index view
This commit is contained in:
		
					parent
					
						
							
								74dfd6d368
							
						
					
				
			
			
				commit
				
					
						182f567304
					
				
			
		
					 1 changed files with 2 additions and 4 deletions
				
			
		| 
						 | 
					@ -5,9 +5,7 @@ data IndexView = IndexView { tasks :: [Task]  }
 | 
				
			||||||
 | 
					
 | 
				
			||||||
instance View IndexView where
 | 
					instance View IndexView where
 | 
				
			||||||
    html IndexView { .. } = [hsx|
 | 
					    html IndexView { .. } = [hsx|
 | 
				
			||||||
        {breadcrumb}
 | 
					        <h1>Tasks<a href={pathTo NewTaskAction} class="btn btn-primary ms-4">+ New</a></h1>
 | 
				
			||||||
 | 
					 | 
				
			||||||
        <h1>Index<a href={pathTo NewTaskAction} class="btn btn-primary ms-4">+ New</a></h1>
 | 
					 | 
				
			||||||
        <div class="table-responsive">
 | 
					        <div class="table-responsive">
 | 
				
			||||||
            <table class="table">
 | 
					            <table class="table">
 | 
				
			||||||
                <thead>
 | 
					                <thead>
 | 
				
			||||||
| 
						 | 
					@ -31,7 +29,7 @@ instance View IndexView where
 | 
				
			||||||
renderTask :: Task -> Html
 | 
					renderTask :: Task -> Html
 | 
				
			||||||
renderTask task = [hsx|
 | 
					renderTask task = [hsx|
 | 
				
			||||||
    <tr>
 | 
					    <tr>
 | 
				
			||||||
        <td>{task}</td>
 | 
					        <td>{task.description}</td>
 | 
				
			||||||
        <td><a href={ShowTaskAction task.id}>Show</a></td>
 | 
					        <td><a href={ShowTaskAction task.id}>Show</a></td>
 | 
				
			||||||
        <td><a href={EditTaskAction task.id} class="text-muted">Edit</a></td>
 | 
					        <td><a href={EditTaskAction task.id} class="text-muted">Edit</a></td>
 | 
				
			||||||
        <td><a href={DeleteTaskAction task.id} class="js-delete text-muted">Delete</a></td>
 | 
					        <td><a href={DeleteTaskAction task.id} class="js-delete text-muted">Delete</a></td>
 | 
				
			||||||
| 
						 | 
					
 | 
				
			||||||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue