Merge branch 'r-1902001-01' into foodcourt

This commit is contained in:
Thein Lin Kyaw
2020-08-04 11:45:01 +06:30
43 changed files with 401 additions and 970 deletions

View File

@@ -20,10 +20,11 @@ class CustomerImageUploader < CarrierWave::Uploader::Base
end
def filename
if Shop.current_shop.nil?
"#{original_filename}" if original_filename.present?
return unless original_filename.present?
if Shop.current_shop.shop_code.nil?
"#{original_filename}"
else
"#{Shop.current_shop.shop_code}_#{original_filename}" if original_filename.present?
"#{Shop.current_shop.shop_code}_#{original_filename}"
end
end