Sha256: b57cc667818671d09f3a1335298c80b6413400ef1956f8f22aeef546c80ec6e4
Contents?: true
Size: 372 Bytes
Versions: 36
Compression:
Stored size: 372 Bytes
Contents
require 'explicit_delegator' module WoopleTheme module Dashboard class PointsPresenter < ExplicitDelegator enforce_definitions :earned, :total def percent_complete return 100 if data.total.zero? ( (data.earned.to_f / data.total.to_f) * 100 ).round end private def data @delegate end end end end
Version data entries
36 entries across 36 versions & 1 rubygems