Project

General

Profile

Test Session in Init.rb

Added by You Ri about 10 years ago

Hello, i try to add an item menu by init.rb. I want that item only if my session[:xAdmin] exist, but I thinks session is not load in this time of excution of program.

So, how i can process ?

Thank

PS : sorry for my bad english

EDIT : My code :

   menu( :account_menu,
      :deconnectForTestUser, 
      "/account/deconnectForTestUser", 
      :caption => 'Retourner à la session Admin', 
      :if => Proc.new{ [test in session[:xAdmin] })


Replies (1)

RE: Test Session in Init.rb - Added by anhkhoa Michel almost 10 years ago

When redmine restart, File init.rb was first load, When redmine do'nt have session.ok!

    (1-1/1)