Mailinglist Archive: opensuse-buildservice (261 mails)

< Previous Next >
Re: [opensuse-buildservice] How to change password?
  • From: Marcus Hüwe <suse-tux@xxxxxx>
  • Date: Fri, 20 Jun 2008 13:10:52 +0200
  • Message-id: <20080620111051.GA3691@xxxxxxxxxxxxxxxxxxx>
On 2008-06-18 22:59:18 +0400, Matwey V. Kornilov wrote:

Hi,

I've installed obs 0.9.99 on my own server. How to change password for
default admin account? There is the page change_password.rhtml in frontend,
but I failed to open it.

Here's a small workaround for password problem (but I'm not sure if this is the
right fix for this bug). This patch also fixes the user deletion bug.


Marcus
Index: app/controllers/active_rbac/user_controller.rb
===================================================================
--- app/controllers/active_rbac/user_controller.rb (Revision 4230)
+++ app/controllers/active_rbac/user_controller.rb (Arbeitskopie)
@@ -20,12 +20,16 @@
:add_flash => { :error => 'You sent an invalid request!' }


+ def initialize
+ @ichain_mode = ichain_mode
+ end
+
# Simply redirects to #list
def index
redirect_to :action => 'list'
end

- def list
+ def list
if params[:onlyunconfirmed]
@user_pages, @users = paginate :user, :conditions => [ "state = 5"],
:order_by => "id", :per_page => 200
else
@@ -51,7 +55,6 @@

# Displays a form to create a new user. Posts to the #create action.
def new
- @ichain_mode = ichain_mode
@user = User.new
end

Index: app/views/active_rbac/user/delete.rhtml
===================================================================
--- app/views/active_rbac/user/delete.rhtml (Revision 4230)
+++ app/views/active_rbac/user/delete.rhtml (Arbeitskopie)
@@ -7,7 +7,7 @@
<strong>This action cannot be reverted!</strong>
</p>

-<% form_for :group, :url => { :action => :delete, :id => @user } do |form| %>
+<% form_for :group, :url => { :action => :destroy, :id => @user } do |form| %>
<%= submit_tag 'Yes', :name => 'yes' %>
<%= submit_tag 'No', :name => 'no' %>
-<% end %>
\ Kein Zeilenvorschub am Ende der Datei
+<% end %>
< Previous Next >
References