Skip to content

Commit

Permalink
Merge branch 'master' of ssh://git.fedorahosted.org/git/katello
Browse files Browse the repository at this point in the history
  • Loading branch information
bkearney committed Oct 13, 2011
2 parents 0798a30 + c497449 commit be6830e
Show file tree
Hide file tree
Showing 14 changed files with 38 additions and 129 deletions.
8 changes: 8 additions & 0 deletions cli/test-system/cli_tests/repo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -9,3 +9,11 @@ REPO_NAME=`$CMD repo list --org="$TEST_ORG" -g | grep $FEWUPS_REPO | awk '{print
REPO_ID=$(get_repo_id)
test_success "repo status" repo status --id="$REPO_ID"
test_success "repo synchronize" repo synchronize --id="$REPO_ID"

PACKAGE_URL=https://localhost/pulp/repos/$TEST_ORT/$TEST_ORG/Locker/$FEWUPS_PRODUCT/$REPO_NAME/lion-0.3-0.8.noarch.rpm
REPO_STATUS_CODE=`curl $PACKAGE_URL -k --write-out '%{http_code}' -s -o /dev/null`
if [ $REPO_STATUS_CODE != '401' ]; then
msg_status "repo secured" "${txtred}FAILED${txtrst}"
echo "We expected the pulp repo to be sucured (status code 401), got $REPO_STATUS_CODE"
let failed_cnt+=1
fi
2 changes: 1 addition & 1 deletion puppet/modules/pulp/templates/etc/pulp/pulp.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ config: /etc/pulp/logging/basic.cfg
[yum]
threads: 15
# True/False to flag if we should remove older rpms
remove_old_packages: false
remove_old_versions: false
# Integer to specify how many old packages to keep.
# Only used if 'removeold' is set to True
num_old_pkgs_keep: 2
Expand Down
10 changes: 4 additions & 6 deletions src/app/controllers/repositories_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,10 @@ class RepositoriesController < ApplicationController

respond_to :html, :js

before_filter :find_provider, :only => [:edit, :update, :destroy, :new, :create]
before_filter :find_provider, :only => [:new, :create, :edit, :destroy]
before_filter :authorize
before_filter :find_product, :only => [:edit, :update, :destroy, :new, :create]
before_filter :find_repository, :only => [:edit, :update, :destroy]
before_filter :find_product, :only => [:new, :create, :edit, :destroy]
before_filter :find_repository, :only => [:edit, :destroy]

def rules
read_test = lambda{@provider.readable?}
Expand All @@ -33,8 +33,6 @@ def rules
}
end



def section_id
'contents'
end
Expand Down Expand Up @@ -69,7 +67,7 @@ def update
end

def destroy
@product.delete_repo(params[:id])
@product.delete_repo_by_id(@repository[:id])
notice _("Repository '#{params[:id]}' removed.")
render :partial => "common/post_delete_close_subpanel", :locals => {:path=>products_repos_provider_path(@provider.id)}
end
Expand Down
13 changes: 3 additions & 10 deletions src/app/controllers/systems_controller.rb
Original file line number Diff line number Diff line change
Expand Up @@ -183,22 +183,15 @@ def edit

def update
begin
unless @system.update_attributes(params[:system])
errors @system.errors
respond_to do |format|
format.html { render :partial => "layouts/notification", :status => :bad_request, :content_type => 'text/html' and return}
format.js { render :partial => "layouts/notification", :status => :bad_request, :content_type => 'text/html' and return}
end
end
@system.update_attributes!(params[:system])
notice _("System updated.")

respond_to do |format|
format.html { render :text=>params[:system].first[1] }
format.js
end

rescue Exception => e
errors @system.errors
rescue Exception => error
errors error.to_s, {:persist => false}
respond_to do |format|
format.html { render :partial => "layouts/notification", :status => :bad_request, :content_type => 'text/html' and return}
format.js { render :partial => "layouts/notification", :status => :bad_request, :content_type => 'text/html' and return}
Expand Down
4 changes: 2 additions & 2 deletions src/app/helpers/menu.rb
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@ def self.included(base)
end
end
def render_menu(level)
@menu_items ||=create_menu
render_navigation(:items=>@menu_items, :expand_all=>true, :level => level)
@menu_items ||= create_menu
render_navigation(:items=>Support.deep_copy(@menu_items), :expand_all=>true, :level => level)
end

def create_menu
Expand Down
6 changes: 6 additions & 0 deletions src/app/models/support.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,10 @@ module Support
def Support.deep_copy object
Marshal::load(Marshal.dump(object))
end

def Support.time
a = Time.now
yield
Time.now - a
end
end
10 changes: 9 additions & 1 deletion src/app/stylesheets/katello.scss
Original file line number Diff line number Diff line change
Expand Up @@ -1707,29 +1707,37 @@ fieldset {
word-wrap: break-word;
border: 1px solid $tree-border_color;
border-bottom: none;

#search_form {
display: none;
margin-right: 4px;
float: left;
}
.search {
position: relative;
clear: both;
display: inline-block;
margin: 5px auto;

input[type="input"] {
//float: right; /* webkit adds an extra padding and makes the widget narrower */
float: left;
border: 3px solid $tree-search-border_color;
background: $white_color;
padding-right: 0px;
width: 380px;
margin-left: 4px;
}
button {
position: absolute;
background: $search_icon_black;
top: 15px;
right: 10px;
}
}
.search_button {
margin-top: 12px;
background: $search_icon_black;
margin-right: 10px;
}
.tree_breadcrumb {
display: inline-block;
Expand Down
3 changes: 1 addition & 2 deletions src/app/stylesheets/sections/operations.scss
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,7 @@
border: 2px solid $kselected_color;
}
#roles_tree {
.close { right: 10px; top: 12px; }
.search_button { right: 40px; }
.close { right: 40px; top: 12px; }
#global{ color: $global_permission_color; }
#remove_role { a { color: $black_color; } }
.breadcrumb_search { border: none; }
Expand Down
2 changes: 0 additions & 2 deletions src/app/views/promotions/show.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -92,12 +92,10 @@
- if read_changesets
%h2 #{@next_environment.name + _(" Changesets")}
.breadcrumb_search.fl.clear.clickable

%form#search_form.search.clear
%input{ :name => "s", :type => "input", :placeholder => "Filter...", :id=>"search_filter"}
%button.action #{_("Search")}
%br.clear

.search_button.fr.clickable
#{_('Search')}
.tree_breadcrumb
Expand Down
1 change: 0 additions & 1 deletion src/app/views/roles/_edit.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
%input{ :name => "s", :type => "input", :placeholder => "Filter...", :id=>"search_filter"}
%button.action #{_("Search")}
%br.clear

.search_button.fr.clickable
#{_('Search')}
.tree_breadcrumb
Expand Down
2 changes: 1 addition & 1 deletion src/app/views/roles/_self_role_edit.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
#{@user.username}

= content_for :remove_item do
- if editable
-if @user.deletable?
= link_to _("Remove User"), { :controller => "users", :action => "destroy", :id => @user.id }, :confirm => _('Are you sure?'), :method => :delete, :class=>"remove_item", :remote=>true

= content_for :navigation do
Expand Down
48 changes: 0 additions & 48 deletions src/public/fonts/demo.html

This file was deleted.

52 changes: 0 additions & 52 deletions src/public/fonts/stylesheet.css

This file was deleted.

6 changes: 3 additions & 3 deletions src/public/javascripts/slidingtree.js
Original file line number Diff line number Diff line change
Expand Up @@ -216,7 +216,7 @@ var sliding_tree = function(tree_id, options) {
}
},
setupSearch = function(){
var bcs = null,
var bcs,
bcs_height = 0,
search_form = $('#search_form'),
search_filter = $('#search_filter');
Expand All @@ -231,10 +231,10 @@ var sliding_tree = function(tree_id, options) {
bcs = $('.breadcrumb_search');
bcs_height = bcs.height();
bcs.animate({ "height": bcs_height+40}, { duration: 200, queue: false });
search_filter.css("margin-left", 0);
search_filter.css("margin-left", '4px');
search_form.css("opacity", "0").show();
search_form.animate({"opacity":"1"}, { duration: 200, queue: false });
search_filter.animate({"width":"420px", "opacity":"1"}, { duration: 200, queue: false });
search_filter.animate({"width": (bcs.width() - 60) + "px", "opacity":"1"}, { duration: 200, queue: false });
$(this).css({backgroundPosition: "-32px -16px"});

if( $('.remove_item').length ){
Expand Down

0 comments on commit be6830e

Please sign in to comment.