OSDN Git Service

t#30322:create provider license import func
[pettanr/pettanr.git] / app / models / license.rb
index bd344c9..388eb0c 100644 (file)
@@ -79,4 +79,11 @@ class License < ActiveRecord::Base
     @credit_pictures_attr
   end
   
+  def self.export(dt = nil)
+    opt = {}
+    opt.merge!({:conditions => ['updated_at >= ?', dt]}) if dt
+#    opt.merge!({:order => 'name'})
+    License.find(:all, opt)
+  end
+  
 end