From: Chris W. <ch...@cw...> - 2003-06-15 10:39:16
|
joseph speigle wrote: > hello, I have started adding themes with data files run from > SQLInstall.pm can users set their theme? Is there any user > configurable way to set theme -- like assigning the theme-number > (1, 2 ..) to {default_objects}{theme} at user-login time or > something like that. Do you have any recommendations as to where > to put this code in my package. I haven't upgraded yet, this is > openinteract-1.57. This used to be an option on the base_user::user_form template but for some reason I removed it. To add it back in, you just need to add a new row something like this: [%- count = count + 1 -%] [% INCLUDE label_form_select_row( label = 'Theme', name = 'theme_id', picked = user.theme_id, list = theme_list, value_field = 'title', label_field => 'theme_id' ) -%] And then add to the show() method OI/Handler/User.pm: $params->{theme_list} = eval { $R->theme->fetch_group({ order => 'title' }) }; And then uncomment a few lines in the edit() method of OI/Handler/User.pm. They're marked already. Good luck! Chris -- Chris Winters (ch...@cw...) Building enterprise-capable snack solutions since 1988. |