OSDN Git Service

arc.url for mmdacc1
authornomeu <nomeu@users.sourceforge.jp>
Sat, 26 Jun 2010 18:24:23 +0000 (03:24 +0900)
committernomeu <nomeu@users.sourceforge.jp>
Sat, 26 Jun 2010 18:24:23 +0000 (03:24 +0900)
app/models/arc.rb
spec/models/arc_spec.rb

index df619f8..b1331c1 100644 (file)
@@ -20,6 +20,8 @@ class Arc < ActiveRecord::Base
       "http://bytatsu.net/uploader/mikumikudance"
     when "file"
       "http://loda.jp/mmdfile"
+    when "mini"
+      "http://www9.atpages.jp/~mmdaccessory/uploader"
     end
   end
 
@@ -37,6 +39,8 @@ class Arc < ActiveRecord::Base
       else
         "#{site}/?id=#{number}"
       end
+    when "mini"
+      "#{site}/log/#{number}.#{extname}"
     end
   end
 
index a10450b..167647c 100644 (file)
@@ -47,6 +47,11 @@ describe Arc do
     arc = Arc.new(:code => 'file0120', :extname => 'zip', :locked => 1)
     arc.url.should == 'http://loda.jp/mmdfile/?mode=pass&idd=120'
   end
+  it do
+    arc = Arc.new(:code => 'mini0910', :extname => 'zip')
+    arc.url.should == "http://www9.atpages.jp/~mmdaccessory/uploader/log/910.zip"
+  end
+
   #
   # number
   #