Sha256: 24fd67b090332c172c09d777c8241803d9f50fbe619c2695f5731b0923a0f80c
Contents?: true
Size: 644 Bytes
Versions: 26
Compression:
Stored size: 644 Bytes
Contents
module TheCity class MetricWriter < ApiWriter # Constructor. # # @param data The json data to save. def initialize(data) if data[:id] @url_action = :put @url_data_path = "/metrics/#{data[:id]}" else @url_action = :post @url_data_path = "/metrics" end @url_data_delete_path = "/metrics/#{data[:id]}" @url_data_params = data @updatable_fields = [:name, :description, :category, :subcategory, :is_percent] end end end
Version data entries
26 entries across 26 versions & 1 rubygems