This commit is contained in:
Edin Dazdarevic
2015-04-13 01:05:40 +02:00
9 changed files with 511 additions and 66 deletions

View File

@@ -2,4 +2,13 @@ class MultiMediaDescription < ActiveRecord::Base
belongs_to :item
belongs_to :media_type
def attributes
super.merge('resized_url' => self.resized_url)
end
def resized_url
url.gsub('/upload/v','/upload/c_lpad,h_170,w_226/v')
end
end