浏览代码

增加商品属性定义

abiao 5 年之前
父节点
当前提交
1fb7563f85
共有 1 个文件被更改,包括 2 次插入0 次删除
  1. 2 0
      app/models/product.rb

+ 2 - 0
app/models/product.rb

@@ -48,6 +48,7 @@ class Product < ActiveRecord::Base
     end
 
     def gross_interest_rate
+=begin
         @Size = ProductAttrConfig.where("product_id=? and size_type='size'",self.id).first
         if !@Size.blank?
             @productAttrs = ProductAttr.where("attr_key_id=?",@Size.id).order("recommend desc")
@@ -56,6 +57,7 @@ class Product < ActiveRecord::Base
                 SIZE_ENUM.push(a)
             end
         end
+=end
         rate = 0
         if self.buy_price != 0 && self.price != 0
             rate = (( self.price.to_f - self.buy_price.to_f )/self.buy_price.to_f)*100