Sha256: e0a9bc4cac9f57deea899c02b3a92e6ea953e9fe9394daf4d93af679e39c22e2

Contents?: true

Size: 888 Bytes

Versions: 17

Compression:

Stored size: 888 Bytes

Contents

module Houston
  module Adapters
    module TicketTracker
      class HoustonAdapter
        class Connection
          attr_reader :project

          def initialize(project)
            @project = project
          end



          # Required API

          def features
            []
          end

          def build_ticket(attributes)
            NullTicket
          end

          def create_ticket!(ticket)
            number = project.tickets.maximum(:number).to_i + 1
            ticket.number = number
            ticket.remote_id = number
            ticket
          end

          def project_url
            "/projects/#{project.slug}"
          end

          def ticket_url(ticket_number)
            "#{project_url}/tickets/by_number/#{ticket_number}"
          end



          def find_ticket_by_number(number)
          end

        end
      end
    end
  end
end

Version data entries

17 entries across 17 versions & 1 rubygems

Version Path
houston-core-0.8.0.pre app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.7.0 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.7.0.beta4 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.7.0.beta3 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.7.0.beta2 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.7.0.beta app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.6.3 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.6.2 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.6.1 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.6.0 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.6 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.5 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.4 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.3 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.2 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.1 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb
houston-core-0.5.0 app/adapters/houston/adapters/ticket_tracker/houston_adapter/connection.rb