abiao 4 年 前
コミット
778e03d8f7
共有1 個のファイルを変更した3 個の追加3 個の削除を含む
  1. 3 3
      app/models/cash_balance.rb

+ 3 - 3
app/models/cash_balance.rb

@@ -41,10 +41,10 @@ class CashBalance < ActiveRecord::Base
       return self.count
     end
   end
-  const total=0
+  $total=0
   def get_happen_total
-    total= total+self.count
-    return total
+    $total= $total+self.count
+    return $total
   end
 
   def profit_state