<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array"/>
  <modified type="array">
    <modified>
      <diff>@@ -1,3 +1,43 @@
 = Regional Exclusivity
 
-Description goes here
\ No newline at end of file
+This extension offers a way to give a customer &quot;regional exclusivity&quot; for an item for a given time and radius. In the case I created this for, a customer would have exclusive purchase protection within a 100 mile radius during a &quot;season&quot; that runs for 12 months of the year. The day after the season ends, the protection resets.
+
+= Defaults
+
+To change the radius or date range for protection, edit these values in 'regional_exclusivity_extension.rb'
+
+    RADIUS                      = 100
+    CURRENT_SEASON_START_DATE   = Date.new( y=Time.now.year, m=1, d=1 )
+
+= Views
+
+This does require some customization of the views to handle the display of the regional protection lookup. I specifically blocked display of the 'add to cart' button unless the check has been passed.
+
+The top of my product show.html.erb looks like this:
+
+    &lt;% if product_price(@product) %&gt;
+    &lt;p class=&quot;prices&quot;&gt;
+      &lt;%= t(&quot;price&quot;) %&gt;
+      &lt;br /&gt;
+      &lt;span class=&quot;price selling&quot;&gt;&lt;%= product_price(@product) %&gt;&lt;/span&gt;
+    &lt;/p&gt;
+    &lt;% end %&gt;
+
+    &lt;% if @product.regionally_protected? &amp;&amp; ( @available.nil? || !@available[:value] ) %&gt;
+      &lt;p class=&quot;regional_exclusivity&quot;&gt;
+        &lt;h2&gt;Regional protection&lt;/h2&gt;
+          &lt;%= '&lt;h3 style=&quot;color: red;&quot;&gt;' + @available[:message] + '&lt;/h3&gt;' unless @available.nil? %&gt;
+          &lt;label&gt;Enter your zip code&lt;/label&gt;&lt;br /&gt;
+          &lt;form action=&quot;&lt;%= request.path %&gt;&quot; method=&quot;get&quot; accept-charset=&quot;utf-8&quot;&gt;
+            &lt;%= text_field_tag( :availableTo, '', :class =&gt; &quot;title&quot;, :size =&gt; 6 ) %&gt;
+            &amp;nbsp;&lt;button type='submit' class='small'&gt;Check Availability&lt;/button&gt;
+          &lt;/form&gt;
+      &lt;/p&gt;
+    &lt;% else %&gt;
+      &lt;%= '&lt;h3 style=&quot;color: green;&quot;&gt;' + @available[:message] + '&lt;/h3&gt;' unless @available.nil? %&gt;
+      &lt;% form_for :order, :url =&gt; orders_url do |f| %&gt;
+      
+      ...
+      
+    &lt;% end %&gt;
+</diff>
      <filename>README.markdown</filename>
    </modified>
  </modified>
  <removed type="array"/>
  <parents type="array">
    <parent>
      <id>a309574baec0b11fea5506afec0480ae32a01973</id>
    </parent>
  </parents>
  <author>
    <name>Tim Harvey</name>
    <email>tim@literacy5.com</email>
  </author>
  <url>http://github.com/tjh/spree-regional-exclusivity/commit/90d2aba86071a99d67d28b18ee43f4da6f82fd93</url>
  <id>90d2aba86071a99d67d28b18ee43f4da6f82fd93</id>
  <committed-date>2009-11-06T11:50:01-08:00</committed-date>
  <authored-date>2009-11-06T11:50:01-08:00</authored-date>
  <message>Added readme details</message>
  <tree>b8f7073ac2eee12424a2a991ef7cb67a2c47be87</tree>
  <committer>
    <name>Tim Harvey</name>
    <email>tim@literacy5.com</email>
  </committer>
</commit>
