Sha256: f7247478f2dccebbf630c210753ee6bdfcaf37aa6a31fab59de495a237b5d9ab
Contents?: true
Size: 693 Bytes
Versions: 21
Compression:
Stored size: 693 Bytes
Contents
require 'securerandom' module BjondApi class BjondAppDefinition attr_accessor :id, :author, :name, :description, :rootEndpoint, :configURL, :iconURL, :rootEndpoint, :integrationEvent, :integrationConsequence def initialize() self.id = SecureRandom.uuid self.configURL = "#{self.get_hostname}/bjond-app/services" self.rootEndpoint = "#{self.get_hostname}/bjond-app/services" self.integrationEvent = [] self.integrationConsequence = [] end def get_hostname() Rails.application.config.action_controller.default_url_options ? Rails.application.config.action_controller.default_url_options[:root_url] : nil || `hostname` end end end
Version data entries
21 entries across 21 versions & 1 rubygems