Sha256: f73fd6b245469cdaa42f6d1419624cfd6e4f0d95d5630f92f6094a0351a96f80
Contents?: true
Size: 690 Bytes
Versions: 28
Compression:
Stored size: 690 Bytes
Contents
require 'pact_broker/ui/controllers/base_controller' require 'pact_broker/ui/view_models/index_items' require 'haml' module PactBroker module UI module Controllers class Index < Base include PactBroker::Services get "/" do tags = nil if params[:tags] tags = params[:tags] == 'true' ? true : [*params[:tags]].compact end view_model = ViewDomain::IndexItems.new(index_service.find_index_items(tags: tags)) page = tags ? :'index/show-with-tags' : :'index/show' haml page, {locals: {index_items: view_model, title: "Pacts"}, layout: :'layouts/main'} end end end end end
Version data entries
28 entries across 28 versions & 1 rubygems