<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>generators/tartarus/templates/spec/controllers/exceptions_controller_spec.rb</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -11,7 +11,8 @@ class TartarusGenerator &lt; Rails::Generator::NamedBase
       puts &quot;\nGenerated files:\n&quot;
       # Directories
       m.directory &quot;app/views/exceptions&quot;
-      m.directory 'spec/models'
+      m.directory &quot;spec/models&quot;
+      m.directory &quot;spec/controllers&quot;
 
       # Configuration
       m.template 'config/exceptions.yml', 'config/exceptions.yml'
@@ -33,6 +34,7 @@ class TartarusGenerator &lt; Rails::Generator::NamedBase
 
       # Specs
       m.template 'spec/models/logged_exception_spec.rb', &quot;spec/models/#{file_name}_spec.rb&quot;
+      m.template 'spec/controllers/exceptions_controller_spec.rb', 'spec/controllers/exceptions_controller_spec.rb'
 
       # Public
       m.file 'public/javascripts/tartarus.jquery.js', 'public/javascripts/tartarus.jquery.js'</diff>
      <filename>generators/tartarus/tartarus_generator.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,10 +1,31 @@
 class ExceptionsController &lt; ApplicationController
   def index
-    @exceptions = &lt;%= class_name %&gt;.all(:select =&gt; '*, COUNT(*) as count', :group =&gt; 'hash_id', :order =&gt; 'created_at DESC')
+    @exceptions = &lt;%= class_name %&gt;.all(:select =&gt; '*, COUNT(*) as count', :group =&gt; 'group_id', :order =&gt; 'created_at DESC')
   end
 
   def details
-    @exceptions = &lt;%= class_name %&gt;.paginate(:all, :conditions =&gt; { :hash_id =&gt; params[:id] }, :order =&gt; 'created_at DESC', :page =&gt; params[:page], :per_page =&gt; 1)
+    @exceptions = &lt;%= class_name %&gt;.paginate(:all, :conditions =&gt; { :group_id =&gt; params[:id] }, :order =&gt; 'created_at DESC', :page =&gt; params[:page], :per_page =&gt; 1)
     @exception = @exceptions.first
   end
+
+  def remove_all
+    &lt;%= class_name %&gt;.delete_all
+    redirect_to :action =&gt; :index
+  end
+
+  def remove_group
+    &lt;%= class_name %&gt;.delete_all(:group_id =&gt; params[:id])
+    redirect_to :action =&gt; :index
+  end
+
+  def remove_individual
+    exception = &lt;%= class_name %&gt;.find_by_id(params[:id])
+    exception.destroy
+
+    if &lt;%= class_name %&gt;.count(:conditions =&gt; { :group_id =&gt; exception.group_id }).zero?
+      redirect_to :action =&gt; :index
+    else
+      redirect_to :action =&gt; :details, :id =&gt; exception.group_id
+    end
+  end
 end</diff>
      <filename>generators/tartarus/templates/app/controllers/exceptions_controller.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,6 @@
-&lt;tr id=&quot;exception_&lt;%= exception.hash_id %&gt;&quot;&gt;
+&lt;tr id=&quot;exception_&lt;%= exception.group_id %&gt;&quot;&gt;
   &lt;td&gt;
-    &lt;strong&gt;&lt;%= link_to &quot;#{exception.exception_class}&quot;, :action =&gt; 'details', :id =&gt; exception.hash_id %&gt;&lt;/strong&gt;
+    &lt;strong&gt;&lt;%= link_to &quot;#{exception.exception_class}&quot;, :action =&gt; 'details', :id =&gt; exception.group_id %&gt;&lt;/strong&gt;
     &lt;br /&gt;
     &lt;span&gt;&lt;%= truncate(exception.message, :length =&gt; 115) %&gt;&lt;/span&gt;
   &lt;/td&gt;</diff>
      <filename>generators/tartarus/templates/app/views/exceptions/_exception.html.erb</filename>
    </modified>
    <modified>
      <diff>@@ -1,17 +1,24 @@
-&lt;div id=&quot;exceptional&quot;&gt;
+&lt;div id=&quot;tartarus&quot;&gt;
   &lt;div id=&quot;exception_group_details&quot;&gt;
-    &lt;div  id=&quot;exceptional_cap&quot;&gt;
-      &lt;div id=&quot;exceptional_nav&quot;&gt;
+    &lt;div  id=&quot;tartarus_cap&quot;&gt;
+      &lt;div id=&quot;tartarus_nav&quot;&gt;
         &lt;%= link_to 'Return to overview', :controller =&gt; 'exceptions', :action =&gt; 'index' %&gt;
-        &lt;%= will_paginate @exceptions, :page_links =&gt; false, :class =&gt; 'exceptional_pagination' %&gt;
+        &lt;%= will_paginate @exceptions, :page_links =&gt; false, :class =&gt; 'tartarus_pagination' %&gt;
       &lt;/div&gt;
       &lt;h2&gt;&lt;%= @exception.exception_class %&gt; in &quot;&lt;%= &quot;#{@exception.controller_path}##{@exception.action_name}&quot; %&gt;&quot;&lt;/h2&gt;
       &lt;div&gt;Viewing Exception &lt;%= params[:page] || 1 %&gt; of &lt;%= @exceptions.total_pages %&gt;&lt;/div&gt;
     &lt;/div&gt;
   &lt;/div&gt;
 
+  &lt;h3&gt;&lt;%= @exception.created_at.strftime(&quot;%B %e %Y at %I:%M:%S%p&quot;) %&gt;&lt;/h3&gt;
   &lt;pre&gt;&lt;%= @exception.message %&gt;&lt;/pre&gt;
 
+  &lt;div id=&quot;exception_actions&quot;&gt;
+    &lt;%= link_to 'Remove all', :action =&gt; 'remove_group', :id =&gt; @exception.group_id %&gt;
+    &amp;middot;
+    &lt;%= link_to 'Remove', :action =&gt; 'remove_individual', :id =&gt; @exception.id %&gt;
+  &lt;/div&gt;
+
   &lt;div id=&quot;exception&quot;&gt;
     &lt;div id=&quot;request_information&quot; class=&quot;togglable&quot;&gt;
       &lt;h3&gt;&lt;a class=&quot;toggle_link&quot; href=&quot;javascript:void(0);&quot;&gt;Request&lt;/a&gt;&lt;/h3&gt;</diff>
      <filename>generators/tartarus/templates/app/views/exceptions/details.html.erb</filename>
    </modified>
    <modified>
      <diff>@@ -1,13 +1,13 @@
-&lt;div id=&quot;exceptional&quot;&gt;
-  &lt;div id=&quot;exceptional_cap&quot;&gt;
-    &lt;div id=&quot;exceptional_nav&quot;&gt;
+&lt;div id=&quot;tartarus&quot;&gt;
+  &lt;div id=&quot;tartarus_cap&quot;&gt;
+    &lt;div id=&quot;tartarus_nav&quot;&gt;
       &lt;a href=&quot;#&quot;&gt;Remove all&lt;/a&gt;
     &lt;/div&gt;
     &lt;h2&gt;Exception Overview&lt;/h2&gt;
     &lt;div&gt;&lt;%= @exceptions.length %&gt; Exceptions&lt;/div&gt;
   &lt;/div&gt;
   
-  &lt;table id=&quot;exceptional_overview&quot;&gt;
+  &lt;table id=&quot;tartarus_overview&quot;&gt;
     &lt;thead&gt;
       &lt;tr&gt;
         &lt;th id=&quot;exception_summary&quot;&gt;Summary&lt;/th&gt;</diff>
      <filename>generators/tartarus/templates/app/views/exceptions/index.html.erb</filename>
    </modified>
    <modified>
      <diff>@@ -1,7 +1,7 @@
 class Add&lt;%= class_name %&gt;Table &lt; ActiveRecord::Migration
   def self.up
     create_table :&lt;%= plural_name %&gt;, :force =&gt; true do |t|
-      t.string   :hash_id
+      t.string   :group_id
       t.string   :exception_class
       t.string   :controller_path
       t.string   :action_name</diff>
      <filename>generators/tartarus/templates/db/migrate/add_logged_exceptions.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,23 +1,26 @@
-#exceptional { margin: 0px 20px }
+#tartarus { margin: 0px 20px }
 
-#exceptional_cap { padding-bottom: 10px; border-bottom: 1px solid #777; margin: 20px 0px; }
-#exceptional h2 { margin: 10px 0px; } 
+#tartarus_cap { padding-bottom: 10px; border-bottom: 1px solid #777; margin: 20px 0px; }
+#tartarus h2 { margin: 10px 0px; } 
 
-#exceptional_nav { float: right }
-.exceptional_pagination { margin-top: 20px; }
+#tartarus_nav { float: right }
+.tartarus_pagination { margin-top: 20px; }
 
-#exceptional table { border-collapse: collapse; width: 100%; }
-#exceptional table tr { border-bottom: 1px solid #E0DFE0; }
-#exceptional table th, #exceptional table td { padding: 5px; }
-#exceptional table th { text-align: left; }
+#tartarus table { border-collapse: collapse; width: 100%; }
+#tartarus table tr { border-bottom: 1px solid #E0DFE0; }
+#tartarus table th, #tartarus table td { padding: 5px; }
+#tartarus table th { text-align: left; }
 
-#exceptional th#exception_location { width: 150px; }
-#exceptional th#exception_date { width: 150px; }
-#exceptional th#exception_count { text-align: center; }
+#tartarus th#exception_location { width: 150px; }
+#tartarus th#exception_date { width: 150px; }
+#tartarus th#exception_count { text-align: center; }
 
-#exceptional pre { -webkit-border-radius: 5px; -moz-border-radius: 5px; font-size: 10px; color: #fff; background-color: #222; padding: 10px; font-family: Consolas, Monaco, 'Courier New', Courier,monospace; }
-#exceptional a, #exceptional a:visited { text-decoration: underline; #bdf; } 
-#exceptional a:hover { #09f }
+#tartarus pre { -webkit-border-radius: 5px; -moz-border-radius: 5px; font-size: 10px; color: #fff; background-color: #222; padding: 10px; font-family: Consolas, Monaco, 'Courier New', Courier,monospace; }
+#tartarus a, #tartarus a:visited { text-decoration: underline; #bdf; } 
+#tartarus a:hover { #09f }
+
+#tartarus #exception { clear: both; }
+#tartarus #exception_actions { float: right; }
 
 .toggle_data { display: none }
 #backtrace_information .toggle_data { display: block; }</diff>
      <filename>generators/tartarus/templates/public/stylesheets/tartarus.css</filename>
    </modified>
    <modified>
      <diff>@@ -1,6 +1,7 @@
 require File.dirname(__FILE__) + '/../spec_helper'
 
 describe &lt;%= class_name %&gt; do 
-  before( :each ) do 
+  it &quot;should include the Tartarus::Logger module&quot; do
+    &lt;%= class_name %&gt;.included_modules.include?(Tartarus::Logger)
   end
 end</diff>
      <filename>generators/tartarus/templates/spec/models/logged_exception_spec.rb</filename>
    </modified>
    <modified>
      <diff>@@ -7,14 +7,15 @@ module Tartarus::Logger
   module ClassMethods
     def log(controller, exception)
       create do |logged_exception|
-        hash_id = &quot;#{exception.class.name}#{exception.message}#{controller.controller_path}#{controller.action_name}&quot;     
+        group_id = &quot;#{exception.class.name}#{exception.message}#{controller.controller_path}#{controller.action_name}&quot; 
+    
         logged_exception.exception_class = exception.class.name
         logged_exception.controller_path = controller.controller_path
         logged_exception.action_name = controller.action_name
         logged_exception.message = exception.message
         logged_exception.backtrace = exception.backtrace * &quot;\n&quot;
         logged_exception.request = normalize_request_data(controller.request)
-        logged_exception.hash_id = Digest::SHA1.hexdigest(hash_id)
+        logged_exception.group_id = Digest::SHA1.hexdigest(group_id)
       end
     end
 </diff>
      <filename>lib/tartarus/logger.rb</filename>
    </modified>
    <modified>
      <diff></diff>
      <filename>spec/rails/db/test.sqlite3</filename>
    </modified>
    <modified>
      <diff>@@ -13,9 +13,9 @@ describe Tartarus::Logger do
       @exception.stub!(:backtrace).and_return(['one', 'two', 'three'])
     end
 
-    it &quot;should create a hash_id for grouping of exceptions that are the same&quot; do
+    it &quot;should create a group_id for grouping of exceptions that are the same&quot; do
       @logged_exception = LoggedException.log(@controller, @exception)
-      @logged_exception.hash_id.should == 'ea61658eacfe0930ae2b318297ab51a3c0b5668c'
+      @logged_exception.group_id.should == 'ea61658eacfe0930ae2b318297ab51a3c0b5668c'
     end
 
     it &quot;should convert the backtrace from an array to a string seperated by newlines&quot; do</diff>
      <filename>spec/tartarus/logger_spec.rb</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>f4b67b38d4a907c025c59cf46dd45f2f68a019b9</id>
    </parent>
  </parents>
  <author>
    <name>Daniel Insley</name>
    <email>dan@viviti.com</email>
  </author>
  <url>http://github.com/dinsley/tartarus/commit/c356c6461f2e991ca36761e2a11fa4a6eb0392ec</url>
  <id>c356c6461f2e991ca36761e2a11fa4a6eb0392ec</id>
  <committed-date>2009-10-21T14:31:54-07:00</committed-date>
  <authored-date>2009-10-21T14:31:54-07:00</authored-date>
  <message>generator base completed</message>
  <tree>2f22b86449dc805c5cb92e1d7731fc0f88fb335e</tree>
  <committer>
    <name>Daniel Insley</name>
    <email>dan@viviti.com</email>
  </committer>
</commit>
