<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>VERSION</filename>
    </added>
    <added>
      <filename>bin/drsetup</filename>
    </added>
    <added>
      <filename>dynamic_reports-0.0.2.gem</filename>
    </added>
    <added>
      <filename>dynamic_reports-0.0.3.gem</filename>
    </added>
    <added>
      <filename>dynamic_reports.gemspec</filename>
    </added>
    <added>
      <filename>lib/dynamic_reports/resources/dynamic_reports.css</filename>
    </added>
    <added>
      <filename>lib/dynamic_reports/resources/dynamic_reports.js</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -1,5 +1,10 @@
 = General
-  * 
+  * Figure out how to all for the creation of a single report definition file within app/reports instead of one per report
+  * Change report definition from the current to something more like 
+  *     report :name do 
+  *         report def options
+  *     end
+  
 = Reports
   * Factory Generators (for records data)
   * Pdf engine option</diff>
      <filename>TODO</filename>
    </modified>
    <modified>
      <diff></diff>
      <filename>dynamic_reports-0.0.0.gem</filename>
    </modified>
    <modified>
      <diff>@@ -183,6 +183,27 @@ module DynamicReports
       def link(column, url, link_options=nil)
         links({:column =&gt; column, :url =&gt; url, :link_options =&gt; link_options})
       end
+      
+      # Define an inline subreport for the report
+      #
+      # Pass parameters within {}.  Parameters are replaced with the row values 
+      # from passed records.  You do NOT need to include a parameter value as a 
+      # report column for it to be used in a link. For example, you might 
+      # want to generate a subreport with an ID field in it but not display that id 
+      # in the actual report.  Just include {id} to do this.
+      #
+      # Example:
+      #
+      # subreport :visits, '/reports/{visit}/details?date={recorded_at}'
+      #
+      # The subreport should be created using the same report definition style 
+      # that you use for any other report.  
+      # 
+      def subreport(column, url, link_options=nil)
+        link_options ||= {}
+        link_options.merge!({:class =&gt; 'sub_report_link'}) 
+        links({:column =&gt; column, :url =&gt; url, :link_options =&gt; link_options})
+      end
 
       # Method for instanciating a report instance on a set of given records.
       #
@@ -200,14 +221,6 @@ module DynamicReports
       def on(records)
         new(records, @options)
       end
-
-      #--
-      # Methods for definining a sub report
-      #def link_column
-      #end
-      #def link_rows
-      #end
-
     end
 
     # Instantiate the report on a set of records.</diff>
      <filename>lib/dynamic_reports/reports.rb</filename>
    </modified>
    <modified>
      <diff>@@ -47,7 +47,11 @@ module DynamicReports
       val = ''
 
       if column_object.is_a?(Hash)
-        column = column_object[:column]
+        if column_object.keys.include?(:column)
+          column = column_object[:column] 
+        else
+          column = column_object.keys.first # =&gt; Josh shortcut :)
+        end
       else
         column = column_object
       end
@@ -73,15 +77,6 @@ module DynamicReports
       val.blank? ? get_record_value(record,column) : val
     end
 
-    def get_record_value(record, column)
-      if record.is_a?(Hash)
-        record[column]
-      elsif record.respond_to?(column.to_sym)
-        record.send(column.to_sym)
-      else
-        column
-      end
-    end
 
     def chart_url(chart,report)
       columns = chart.columns ? chart.columns : report.columns
@@ -212,7 +207,15 @@ module DynamicReports
       require engine.downcase
     end
 
-
+     def get_record_value(record, column)
+        if record.is_a?(Hash)
+          record[column]
+        elsif record.respond_to?(column.to_sym)
+          record.send(column.to_sym)
+        else
+          column
+        end
+      end
 
   end
 end</diff>
      <filename>lib/dynamic_reports/templates.rb</filename>
    </modified>
    <modified>
      <diff>@@ -1,51 +1,3 @@
-&lt;% if report.class_name.nil? %&gt;
-&lt;style type=&quot;text/css&quot;&gt;
-.dynamic_report .report_title {
-  font-size:16pt;
-  font-weight:bold;
-  margin:10px 0px;
-}
-.dynamic_report .report_subtitle {
-  font-size:14pt;
-  color:black;
-  margin:10px 0px;
-}
-.dynamic_report table tr th {
-  color: white;
-  background: gray;
-  padding:5px;
-}
-.dynamic_report table tr td {
-  border: 1px solid black;
-  padding:3px 15px;
-}
-.dynamic_report .report_charts {
-  width: 100%;
-}
-
-.dynamic_report .report_chart {
-  margin:15px;
-}
-
-.dynamic_report .subreport_row td {
-  padding: 10px 10px 10px 20px;
-  background-color: #FFFFCC;
-  font-size: 95%;
-}
-.dynamic_report .subreport table tr td {
-  border: 1px dotted #CCCC99;
-  padding:3px 5px;
-  background-color: white;
-}
-.dynamic_report .subreport table tr th {
-  color: black;
-  background: #CCCCCC;
-  padding:3px;
-}
-
-&lt;/style&gt;
-&lt;% end %&gt;
-
 &lt;div id=&quot;&lt;%= report.class_name %&gt;&quot; class=&quot;dynamic_report&quot;&gt;
 &lt;%= &quot;&lt;div class='report_title'&gt;#{report.title}&lt;/div&gt;&quot; if report.title %&gt;
 &lt;%= &quot;&lt;div class='report_subtitle'&gt;#{report.sub_title}&lt;/div&gt;&quot; if report.sub_title %&gt;
@@ -58,7 +10,7 @@
   &lt;% if column.keys.include?(:heading) %&gt;
   &lt;%= options[:titleize] ? titleize(column[:heading]) : column[:heading] %&gt;
   &lt;% else %&gt;
-  &lt;%= options[:titleize] ? titleize(column[:column]) : column[:column] %&gt;
+  &lt;%= options[:titleize] ? titleize(column.values.first) : column.values.first  %&gt;
   &lt;% end %&gt;
   &lt;% else %&gt;
   &lt;%= options[:titleize] ? titleize(column) : column %&gt;
@@ -87,5 +39,4 @@
         &lt;/span&gt;
         &lt;% end %&gt;
         &lt;/div&gt;
-
         &lt;/div&gt;</diff>
      <filename>lib/dynamic_reports/views/default_report.html.erb</filename>
    </modified>
    <modified>
      <diff>@@ -1,46 +1,3 @@
-- if report.class_name.nil?
-  %style{type =&gt; &quot;text/css&quot;}
-    \.dynamic_report .report_title {
-    font-size:16pt;
-    font-weight:bold;
-    margin:10px 0px;
-    }
-    \.dynamic_report .report_subtitle {
-    font-size:14pt;
-    color:black;
-    margin:10px 0px;
-    }
-    \.dynamic_report table tr th {
-    color: white;
-    background: #666666;
-    padding:5px;
-    }
-    \.dynamic_report table tr td {
-    border: 1px solid #333333;
-    padding:3px 15px;
-    }
-    \.dynamic_report .report_charts {
-    width:100%;
-    }
-    \.dynamic_report .report_chart {
-    margin:15px;
-    }
-    \.dynamic_report .subreport_row td {
-    padding: 10px 10px 10px 20px;
-    background-color: #FFFFCC;
-    font-size: 95%;
-    }
-    \.dynamic_report .subreport table tr td {
-    border: 1px dotted #CCCC99;
-    padding:3px 5px;
-    background-color: white;
-    }    
-    \.dynamic_report .subreport table tr th {
-    color: black;
-    background: #CCCCCC;
-    padding:3px;
-    }
-
 .dynamic_report{ :id =&gt; report.class_name }
   - if report.title
     %h2.report_title
@@ -59,7 +16,7 @@
               - if column.keys.include?(:heading)            
                 = options[:titleize] ? titleize(column[:heading]) : column[:heading]
               -else
-                = options[:titleize] ? titleize(column[:column]) : column[:column]                
+                = options[:titleize] ? titleize(column.values.first) : column.values.first              
             -else
               = options[:titleize] ? titleize(column) : column
     %tbody.report_body</diff>
      <filename>lib/dynamic_reports/views/default_report.html.haml</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>1b4cf33adf3bac68919c76b9cbb4961b681941a7</id>
    </parent>
    <parent>
      <id>59f6efebe478c351b3917c550a17b29e8ce19d74</id>
    </parent>
  </parents>
  <author>
    <name>Wayne E. Seguin</name>
    <email>wayneeseguin@gmail.com</email>
  </author>
  <url>http://github.com/wayneeseguin/dynamic_reports/commit/689893ef513175850ba27c5721f857dc3a1a83ee</url>
  <id>689893ef513175850ba27c5721f857dc3a1a83ee</id>
  <committed-date>2009-07-16T07:46:04-07:00</committed-date>
  <authored-date>2009-07-16T07:46:04-07:00</authored-date>
  <message>Merge conflict resolution.</message>
  <tree>5a13ffd0a0001c9c2e37580c27bfc3c3def52824</tree>
  <committer>
    <name>Wayne E. Seguin</name>
    <email>wayneeseguin@gmail.com</email>
  </committer>
</commit>
